Coder Social home page Coder Social logo

welcome-coordinator's Introduction

WelcomeCoordinator

Welcome Coordinator is a library for Android will helps you to create really awesome welcome wizards for your Apps, but this is not all, also you can use the library to create form wizards really nice. Take a look to how you would integrate Welcome Coordinator into your App.

Latest Version

Download Build Status Android Arsenal

How to use

1.- Configuring your project dependencies

Add the library dependency to your build.gradle file.

dependencies {
    ...
    compile 'com.redbooth:WelcomeCoordinator:1.0.1'
}

2.- Adding and Customizing the View

Add the view to your xml layout file.

<com.redbooth.WelcomeCoordinatorLayout
        android:id="@+id/coordinator"
        android:layout_width="match_parent"
        android:layout_height="match_parent" />

3.- Modeling the Pages

Modeling your welcome pages it's really easy, you only needs to create a simple layout resource. Let me an appointment about WelcomePageLayout, the behavior of the layout is the same of the RelativeLayout.

<com.redbooth.WelcomePageLayout
    xmlns:android="http://schemas.android.com/apk/res/android">
    
    ...
    
</com.redbooth.welcomecoordinator.WelcomePageLayout>

WARNING Don't forget create a WelcomePageLayout as root element of your page.

4.- Adding the Pages to Coordinator

@Override
protected void onCreate(Bundle savedInstanceState) {
    ...
    final WelcomeCoordinatorLayout coordinatorLayout 
            = (WelcomeCoordinatorLayout)findViewById(R.id.coordinator); 
    coordinatorLayout.addPage(R.layout.welcome_page_1,
                              ...,
                              R.layout.welcome_page_4);
}

5.- Building your own Behaviors

If you want to have behaviour on your page views when the user navigate inside of your welcome, you can create you own behaviors.

public class ParallaxTitleBehaviour extends WelcomePageBehavior {
    @Override
    protected void onCreate(WelcomeCoordinatorLayout coordinator) {
        ...
    }
    
    @Override
    protected void onPlaytimeChange(WelcomeCoordinatorLayout coordinator,
                                    float newPlaytime,
                                    float newScrollPosition) {
        ...
    }
}

6.- SettingUp your own Behaviors

<com.redbooth.WelcomePageLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto">
    
    <TextView
        ...
        app:view_behavior=".ParallaxTitleBehaviour" />
            
</com.redbooth.welcomecoordinator.WelcomePageLayout>

Developers

Motivation

We created this view as a little piece of the Redbooth App for Android.

License

Copyright Txus Ballesteros & Francisco Sirvent 2016

This file is part of some open source application.

Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

welcome-coordinator's People

Contributors

txusballesteros avatar narfss avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.