{"id":13715949,"url":"https://github.com/Yalantis/StarWars.Android","last_synced_at":"2025-05-07T05:32:03.119Z","repository":{"id":52211712,"uuid":"47962772","full_name":"Yalantis/StarWars.Android","owner":"Yalantis","description":"This component implements transition animation to crumble view into tiny pieces.","archived":false,"fork":false,"pushed_at":"2022-09-22T09:35:33.000Z","size":18294,"stargazers_count":1940,"open_issues_count":14,"forks_count":302,"subscribers_count":86,"default_branch":"master","last_synced_at":"2025-04-08T00:34:27.998Z","etag":null,"topics":["android","animation","glsl","java","opengl","opengl-es","transition"],"latest_commit_sha":null,"homepage":"https://yalantis.com/blog/star-wars-the-force-awakens-or-how-to-crumble-view-into-tiny-pieces-on-android/","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Yalantis.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-12-14T08:50:11.000Z","updated_at":"2025-03-04T02:17:59.000Z","dependencies_parsed_at":"2022-09-04T08:30:48.938Z","dependency_job_id":null,"html_url":"https://github.com/Yalantis/StarWars.Android","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Yalantis%2FStarWars.Android","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Yalantis%2FStarWars.Android/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Yalantis%2FStarWars.Android/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Yalantis%2FStarWars.Android/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Yalantis","download_url":"https://codeload.github.com/Yalantis/StarWars.Android/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252823102,"owners_count":21809700,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android","animation","glsl","java","opengl","opengl-es","transition"],"created_at":"2024-08-03T00:01:05.386Z","updated_at":"2025-05-07T05:31:58.070Z","avatar_url":"https://github.com/Yalantis.png","language":"Java","readme":"# StarWars.Android\n\n[![License](http://img.shields.io/badge/license-MIT-green.svg?style=flat)]()\n[![Maven](https://img.shields.io/maven-central/v/com.yalantis/starwarstiles.svg)]()\n[![](https://jitpack.io/v/yalantis/starwars.android.svg)](https://jitpack.io/#yalantis/starwars.android)\n[![Yalantis](https://raw.githubusercontent.com/Yalantis/PullToRefresh/develop/PullToRefreshDemo/Resources/badge_dark.png)](https://yalantis.com/?utm_source=github)\n\nThis component implements transition animation to crumble view into tiny pieces.\n\n\n\n\u003cimg src=\"star_wars-concept.gif\" /\u003e\n\u003cbr\u003eCheck this \u003ca href=\"https://dribbble.com/shots/2109991-Star-Wars-App-concept\"\u003eproject on dribbble\u003c/a\u003e.\n\nAlso, read how it was done in [our blog](https://yalantis.com/blog/star-wars-the-force-awakens-or-how-to-crumble-view-into-tiny-pieces-on-android)\n\n##Requirements\n- Android SDK 15+\n- OpenGL ES 2.0+\n\n##Usage\n\nAdd to your module's build.gradle:\n```Groovy\ndependencies {\n    //...\n    compile 'com.yalantis:starwarstiles:0.1.1'\n}\n```\n\nWrap your fragment or activity main view in TilesFrameLayout:\n```xml\n\u003ccom.yalantis.starwars.TilesFrameLayout\n  android:id=\"@+id/tiles_frame_layout\"\n  android:layout_height=\"match_parent\"\n  android:layout_width=\"match_parent\"\n  app:sw_animationDuration=\"1500\"\n  app:sw_numberOfTilesX=\"35\"\u003e\n\n  \u003c!-- Your views go here --\u003e\n     \n\u003c/com.yalantis.starwars.TilesFrameLayout\u003e\n```\n\n\nAdjust animation with these parameters:\n- ```app:sw_animationDuration``` – duration in milliseconds\n- ```app:sw_numberOfTilesX``` –  the number of square tiles the plane is tessellated into broadwise\n\n```java\nmTilesFrameLayout = (TilesFrameLayout) findViewById(R.id.tiles_frame);\nmTilesFrameLayout.setOnAnimationFinishedListener(this);\n```\nIn your activity or fragment’s onPause() and onResume() it’s important to call the corresponding methods:\n```java\n@Override\npublic void onResume() {\n    super.onResume();\n    mTilesFrameLayout.onResume();\n}\n\n@Override\npublic void onPause() {\n    super.onPause();\n    mTilesFrameLayout.onPause();\n}\n```\nTo start the animation simply call:\n```java\nmTilesFrameLayout.startAnimation();\n```\nYour callback will be called when the animation ends:\n```java\n@Override\npublic void onAnimationFinished() {\n   // Hide or remove your view/fragment/activity here\n}\n```\n\nHave fun! :)\n\n#### Let us know!\n\nWe’d be really happy if you sent us links to your projects where you use our component. Just send an email to github@yalantis.com And do let us know if you have any questions or suggestion regarding the animation. \n\nP.S. We’re going to publish more awesomeness wrapped in code and a tutorial on how to make UI for iOS (Android) better than better. Stay tuned!\n\n## License\n\n\tThe MIT License (MIT)\n\n\tCopyright © 2017 Yalantis, https://yalantis.com\n\n\tPermission is hereby granted, free of charge, to any person obtaining a copy\n\tof this software and associated documentation files (the \"Software\"), to deal\n\tin the Software without restriction, including without limitation the rights\n\tto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n\tcopies of the Software, and to permit persons to whom the Software is\n\tfurnished to do so, subject to the following conditions:\n\n\tThe above copyright notice and this permission notice shall be included in\n\tall copies or substantial portions of the Software.\n\n\tTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n\tIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n\tFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n\tAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n\tLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n\tOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n\tTHE SOFTWARE.\n\n","funding_links":[],"categories":["Java","ALL"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FYalantis%2FStarWars.Android","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FYalantis%2FStarWars.Android","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FYalantis%2FStarWars.Android/lists"}