kandi background
Explore Kits

AKParallax-Android | Library Project that provides a parallax effect | Animation library

 by   ygorbarboza Java Version: Current License: No License

 by   ygorbarboza Java Version: Current License: No License

Download this library from

kandi X-RAY | AKParallax-Android Summary

AKParallax-Android is a Java library typically used in User Interface, Animation, React Native applications. AKParallax-Android has no bugs, it has no vulnerabilities, it has build file available and it has low support. You can download it from GitHub.
AKParallax-Android is a Library Project that provides a parallax effect to an imageView in a ScrollView or a ListView.
Support
Support
Quality
Quality
Security
Security
License
License
Reuse
Reuse

kandi-support Support

  • AKParallax-Android has a low active ecosystem.
  • It has 251 star(s) with 100 fork(s). There are 20 watchers for this library.
  • It had no major release in the last 12 months.
  • There are 7 open issues and 2 have been closed. On average issues are closed in 133 days. There are no pull requests.
  • It has a neutral sentiment in the developer community.
  • The latest version of AKParallax-Android is current.
AKParallax-Android Support
Best in #Animation
Average in #Animation
AKParallax-Android Support
Best in #Animation
Average in #Animation

quality kandi Quality

  • AKParallax-Android has 0 bugs and 0 code smells.
AKParallax-Android Quality
Best in #Animation
Average in #Animation
AKParallax-Android Quality
Best in #Animation
Average in #Animation

securitySecurity

  • AKParallax-Android has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
  • AKParallax-Android code analysis shows 0 unresolved vulnerabilities.
  • There are 0 security hotspots that need review.
AKParallax-Android Security
Best in #Animation
Average in #Animation
AKParallax-Android Security
Best in #Animation
Average in #Animation

license License

  • AKParallax-Android does not have a standard license declared.
  • Check the repository for any license declaration and review the terms closely.
  • Without a license, all rights are reserved, and you cannot use the library in your applications.
AKParallax-Android License
Best in #Animation
Average in #Animation
AKParallax-Android License
Best in #Animation
Average in #Animation

buildReuse

  • AKParallax-Android releases are not available. You will need to build from source code and install.
  • Build file is available. You can build the component from source.
  • Installation instructions are not available. Examples and code snippets are available.
  • AKParallax-Android saves you 277 person hours of effort in developing the same functionality from scratch.
  • It has 670 lines of code, 38 functions and 28 files.
  • It has medium code complexity. Code complexity directly impacts maintainability of the code.
AKParallax-Android Reuse
Best in #Animation
Average in #Animation
AKParallax-Android Reuse
Best in #Animation
Average in #Animation
Top functions reviewed by kandi - BETA

kandi has reviewed AKParallax-Android and discovered the below as its top functions. This is intended to give you an instant insight into AKParallax-Android implemented functionality, and help decide if they suit your requirements.

  • Initializes the view .
    • Override in order to perform over the onScrollBy method .
      • Initializes the parallax .
        • Calculates the bounds of the view based on the zoom ratio .
          • Override to notify on touch events
            • Apply a transformation to the view
              • Called to initialize the view .
                • On create options menu .

                  Get all kandi verified functions for this library.

                  Get all kandi verified functions for this library.

                  AKParallax-Android Key Features

                  Import the app folder as an Android project. The .project included will cause it to have the name Parallax.

                  default

                  copy iconCopydownload iconDownload
                    <net.appkraft.parallax.ParallaxScrollView xmlns:android="http://schemas.android.com/apk/res/android"
                      xmlns:tools="http://schemas.android.com/tools"
                      xmlns:app="http://schemas.android.com/apk/res/com.appkraft.parallax_sample"
                      android:id="@+id/scrollView1"
                      android:layout_width="match_parent"
                      android:layout_height="match_parent"
                      android:overScrollMode="never"
                      app:zoomRatio="1.4" >
                  
                      <RelativeLayout
                          android:layout_width="match_parent"
                          android:layout_height="1000dp"
                          tools:context=".MainActivity" >
                  
                          <RelativeLayout
                              android:id="@+id/relativeLayout1"
                              android:layout_width="match_parent"
                              android:layout_height="wrap_content"
                              tools:context=".MainActivity" >
                  
                              <ImageView
                                  android:id="@+id/imageView1"
                                  android:layout_width="match_parent"
                                  android:layout_height="100dp"
                                  android:src="@drawable/teste" />
                  
                              <TextView
                                  android:id="@+id/textView1"
                                  android:layout_width="wrap_content"
                                  android:layout_height="wrap_content"
                                  android:layout_alignParentBottom="true"
                                  android:layout_alignParentLeft="true"
                                  android:text="Bottom"
                                  android:textColor="#ffffff"
                                  android:textSize="18sp" />
                  
                              <TextView
                                  android:id="@+id/textView2"
                                  android:layout_width="wrap_content"
                                  android:layout_height="wrap_content"
                                  android:layout_alignParentLeft="true"
                                  android:layout_alignParentTop="true"
                                  android:text="Top"
                                  android:textColor="#ffffff"
                                  android:textSize="18sp" />
                          </RelativeLayout>
                  
                          <TextView
                              android:layout_width="wrap_content"
                              android:layout_height="wrap_content"
                              android:layout_alignParentLeft="true"
                              android:layout_below="@+id/relativeLayout1"
                              android:text="@string/hello_world" />
                      </RelativeLayout>
                  
                  </net.appkraft.parallax.ParallaxScrollView>

                  Community Discussions

                  Trending Discussions on Animation
                  • Xamarin.Forms animation inside Listview stops working if collection changes
                  • How to repeat Android Animation
                  • How to detect that a button is pressed in Jetpack Compose?
                  • SVG stop running chained animation (<animate> tag)
                  • additionalSafeAreaInsets is not accounted for during view controller dismissal, using custom UIViewControllerTransitioningDelegate
                  • How can I prevent my Animations from starting when the other animations are playing?
                  • SwiftUI view animates at unexpected path
                  • Vue.js CSS animation not working correctly when using v-if
                  • Animating wave pulse using matplotlib
                  • How do I disable UIStackView default show/hide animation?
                  Trending Discussions on Animation

                  QUESTION

                  Xamarin.Forms animation inside Listview stops working if collection changes

                  Asked 2022-Mar-22 at 05:34

                  I am having a hard time figuring what's going on with my animation.

                  Viewmodel is composed of an ObservableCollection and every item contains a child ObservableCollection.

                  Parents collection is bound to a BindableLayout. The ItemTemplate of that layout contains a Listview to display child's elements.

                  <StackLayout BindableLayout.ItemsSource ="{Binding Parents}">
                      <BindableLayout.ItemTemplate>
                          <DataTemplate x:DataType="models:ParentRows">
                              <StackLayout>      
                                  <Grid BackgroundColor="White" >
                                       <!-- Some bindable content there -->
                                  </Grid>
                              
                                 <ListView ItemsSource="{Binding Childs}" CachingStrategy="RecycleElementAndDataTemplate" RowHeight="50">
                                      <ListView.ItemTemplate>
                                          <DataTemplate x:DataType="models:ChildRows">
                                              <ViewCell>
                                                  <StackLayout BackgroundColor="White">
                                                      <controls:AnimatedGrid Refresh="{Binding Animation}"
                                                            <!-- Some bindable content there -->
                                                      </controls:AnimatedGrid>
                                                  </StackLayout>
                                              </ViewCell>
                                          </DataTemplate>
                                      </ListView.ItemTemplate>
                                  </ListView>
                              </StackLayout>
                          </DataTemplate>
                      </BindableLayout.ItemTemplate>
                  </StackLayout>
                  

                  I am using an AnimatedGrid on the child listview, this control is inherinting from Grid. It has an extra BindableProperty nammed Refresh and an Animation code that gets called whenever Refresh property changes.

                          private async void AnimateItem()
                          {
                              await Device.InvokeOnMainThreadAsync(() =>
                              {
                                  this.RotateTo(360,500);
                              });
                          }
                  

                  Everything works fine until i start filtering the list. Once i filter the list, subsequent call of AnimateItem will have no effect. To be more precise, if parent item got removed from list, and then added again, childs of this parent will never animate again. Filtering the List consist of Removing/Inserting parents to the observable collection (myCollection.Remove(item), myCollection.Insert(index, item), using Collection methods from framework).

                  This does not seems to be an observable collection binding issue, as values inside parent and childs collection still update perfectly find. Changing CachingStrategy also have no impact on the issue.

                  I found that, if i replace the ListView control by a CollectionView, the problem disappear. However, i realy want to find a solution that would alow me to keep the listview control as switching to CollectionView would introduce to many other undesirable effect.

                  Edit 22/02/2022 : I made a sample project to reproduce the issue on github.

                  • Basicaly, you can click the "Rotate Random" multiple time to make random child spin.
                  • Once you click the "Remove and add 2 parent", you can see that the removed/reinserted items does not rotate anymore.

                  Edit 15/03/2022 : I am still not able to figure what's wrong. However, for test purpose, i added in the control constructor, a task.delay followed by an animation call, and this call is working on filtered items. That's beyond my understanding.

                  ANSWER

                  Answered 2022-Mar-22 at 05:16
                  The solution

                  In your AnimatedGrid class, add an isAttached flag, and add the following lines to your OnPropertyChanged override:

                  bool isAttached = false;
                  
                  protected override void OnPropertyChanged([CallerMemberName] string propertyName = null)
                  {
                      base.OnPropertyChanged(propertyName);
                  
                      if (propertyName == "Renderer")
                      {
                          isAttached = !isAttached;
                          if (!isAttached) this.RemoveBinding(RefreshProperty);
                      }
                  
                      if (propertyName == nameof(Refresh))
                      {
                      ...
                  
                  The why

                  Disclaimer: it took me a long time to figure out what was going on here, and although i was able to fix the problem, i would not claim that i completely and perfectly understand it. I believe this is a bug in Xamarin, and in your case i would file an issue in Github (although maybe MAUI will have this corrected...)

                  When a ChildItem is removed (do Filter), the old ChildItem-AnimatedGrid's Refresh property remains bound to the ChildItem's AnimationInt property.

                  When a ChildItem is added again (remove Filter), a new view is created.

                  Now the problem is evident: when the ChildItem's AnimationInt property changes (tap on ROTATE RANDOM button) the old ChildItem-AnimatedGrid's Refresh is notified, and then the old View is rotated, but the new ramains unchanged (it does not rotate).


                  Once the problem is understood, we need to figure out how to remove the binding of the old view when the view is dettached: well, to do this i used the fact that the VisualElement's Renderer property is set/modified when the element is attached and again when it is detached: The fist time it is called i set the isAttached flag to true. The second time it is called i set the flag to false, and i remove the binding. Removing the binding of the old View allows the new View to be correctly bound.

                  Source https://stackoverflow.com/questions/71190208

                  Community Discussions, Code Snippets contain sources that include Stack Exchange Network

                  Vulnerabilities

                  No vulnerabilities reported

                  Install AKParallax-Android

                  You can download it from GitHub.
                  You can use AKParallax-Android like any standard Java library. Please include the the jar files in your classpath. You can also use any IDE and you can run and debug the AKParallax-Android component as you would do with any other Java program. Best practice is to use a build tool that supports dependency management such as Maven or Gradle. For Maven installation, please refer maven.apache.org. For Gradle installation, please refer gradle.org .

                  Support

                  For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .

                  DOWNLOAD this Library from

                  Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from
                  over 430 million Knowledge Items
                  Find more libraries
                  Reuse Solution Kits and Libraries Curated by Popular Use Cases
                  Explore Kits

                  Save this library and start creating your kit

                  Share this Page

                  share link
                  Consider Popular Animation Libraries
                  Try Top Libraries by ygorbarboza
                  Compare Animation Libraries with Highest Support
                  Compare Animation Libraries with Highest Quality
                  Compare Animation Libraries with Highest Security
                  Compare Animation Libraries with Permissive License
                  Compare Animation Libraries with Highest Reuse
                  Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from
                  over 430 million Knowledge Items
                  Find more libraries
                  Reuse Solution Kits and Libraries Curated by Popular Use Cases
                  Explore Kits

                  Save this library and start creating your kit

                  • © 2022 Open Weaver Inc.