Git Product home page Git Product logo

welcome-android's Issues

Error in overriding configuration and related color issues

In the following code, I got two errors

public class MyWelcomeActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_my_welcome);
    }


    @Override
    protected WelcomeScreenConfiguration configuration() {
        return new WelcomeScreenBuilder(this)
                .theme(R.style.WelcomeScreenTheme_Light)
                .defaultBackgroundColor(new BackgroundColor(Color.RED))
                .titlePage(R.drawable.logotest, "Title")
                .basicPage(R.drawable.photo1test, "Header", "More text.", new BackgroundColor(Color.GREEN));
                .basicPage(R.drawable.photo2test, "Lorem ipsum", "dolor sit amet.")
                .swipeToDismiss(true)
                .build();
    }
}

Error 1: There is no override of configuration()
Error 2: The .basicPage that has a background color was expecting an integer, but the wrapper of background color does not return such an integer.

What can I do?
Thanks!

help

Caused by: android.view.InflateException: Binary XML file line #30: Binary XML file line #30: You must supply a layout_height attribute.
at android.view.LayoutInflater.inflate(LayoutInflater.java:551)
at android.view.LayoutInflater.inflate(LayoutInflater.java:429)
at android.view.LayoutInflater.inflate(LayoutInflater.java:380)
at android.support.v7.app.AppCompatDelegateImplV9.setContentView(AppCompatDelegateImplV9.java:287)
at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:139)
at com.stephentuso.welcome.WelcomeActivity.onCreate(WelcomeActivity.java:33)

Bottom Bar Background

we can't change the bottom bar background for each page. I used FullscreenParallaxPage with customize layout, but botttom bar can't change according to color of current page.

Remove allowbackup from manifest

Hi,

I'm getting the following error while including your library:

Attribute application@allowBackup value=(false) from AndroidManifest.xml:13:9-36
    is also present at [com.stephentuso:welcome:0.7.1] AndroidManifest.xml:12:9-35 value=(true).
    Suggestion: add 'tools:replace="android:allowBackup"' to <application> element at AndroidManifest.xml:11:5-79:19 to override.
See http://g.co/androidstudio/manifest-merger for more information about the manifest merger.
:app:processDebugManifest FAILED
Error:Execution failed for task ':app:processDebugManifest'.
> Manifest merger failed with multiple errors, see logs

As adviced by the error, overriding works, but anyway I think you should remove android:allowBackup="true" from the library manifest. since I think it is useless for a library project.

Thanks & Regards
Marcello

Welcome Screen shows only one time

Hi
at first i thank you for your good library...
i use it with the default configuration you explain at introduction page of Github...
but when i install my app in mobile i see welcome screen one time, and on another use this page is invisible...
i want to see it every time my application is started not only in first use...

best thanks...

Persistent Back Button + more

Hi,

What an awesome project!

I'm using your library to create an instructional slide show, rather than using it as a conventional welcome screen. Therefore, I'd like to have persistently available back and forward buttons, and discard the skip and done buttons.

  1. Is it possible to have a persistent back button, that can be used in a similar fashion to the forward button, allowing the user to navigate using a back and forward button in addition to swiping.
  2. How do i allow for the activity to be "relaunched" after it has been "completed" by the user?
  3. Is it possible to include a actionbar, allowing the user to navigate to the parent activity?

Thanks in advance!

App crash at WelcomeHelper

Here is logcat

03-24 06:48:01.122 4030-4030/com.stephentuso.welcomeexample E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.stephentuso.welcomeexample, PID: 4030
java.lang.NoClassDefFoundError: Failed resolution of: Lorg/jacoco/agent/rt/internal_b0d6a23/Offline;
at com.stephentuso.welcome.WelcomeHelper.$jacocoInit(WelcomeHelper.java:0)
at com.stephentuso.welcome.WelcomeHelper.(WelcomeHelper.java:25)
at com.stephentuso.welcomeexample.MainActivity.onCreate(MainActivity.java:38)
at android.app.Activity.performCreate(Activity.java:6672)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1140)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2612)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2724)
at android.app.ActivityThread.-wrap12(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1473)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6123)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:867)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:757)
Caused by: java.lang.ClassNotFoundException: Didn't find class "org.jacoco.agent.rt.internal_b0d6a23.Offline" on path: DexPathList[[zip file "/data/app/com.stephentuso.welcomeexample-1/base.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_dependencies_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_0_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_1_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_2_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_3_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_4_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_5_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_6_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_7_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_8_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_9_apk.apk"],nativeLibraryDirectories=[/data/app/com.stephentuso.welcomeexample-1/lib/arm, /system/lib, /vendor/lib]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
at java.lang.ClassLoader.loadClass(ClassLoader.java:380)
at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
at com.stephentuso.welcome.WelcomeHelper.$jacocoInit(WelcomeHelper.java:0) 
at com.stephentuso.welcome.WelcomeHelper.(WelcomeHelper.java:25) 
at com.stephentuso.welcomeexample.MainActivity.onCreate(MainActivity.java:38) 
at android.app.Activity.performCreate(Activity.java:6672) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1140) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2612) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2724) 
at android.app.ActivityThread.-wrap12(ActivityThread.java) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1473) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:154) 
at android.app.ActivityThread.main(ActivityThread.java:6123) 
at java.lang.reflect.Method.invoke(Native Method) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:867) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:757) 

i attached the screenshot of class and line no where it show the error.

capture1

Missing symbols

I configured my WelcomeActivity following the read me guide but on execution my project crashes with the following message in Logcat:

No field view_pager of type I in class com/stephentuso/welcome/R.id; or its superclasses

I'm using the Android Emulator (API 24) for testing.

Is this a known issue? If so, are there any workarounds?

Clearing the preferences for when app is reset

Hello and thanks for this awesome library.

I want to know if there's an inbuilt method to clear the welcome activity's preferences from any where in the code. I am implementing a reset button which clears the app's shared preferences and restarts the application. But on restarting, the welcome activity is still not shown which means it's own preferences were still intact.

Thanks once again.

More page layout options

Now that in 1.0 the builder page method only takes a WelcomePage, rather than a bunch of different methods and parameters for each page type, it is much easier to add some more options. For the basic page, title page, and parallax page, I'm thinking the layout options would be the current (text on bottom, large image), text on top with large image, and more centered text with smaller image. Each class could then have a layout method that used an enum perhaps, and then a different layout file would be used based on that.

Shows the same WelcomeScreen in two different sittuations

It's more a question than an issue.

I have this case: I created a welcome screen for my app, it's like my app's overview. But I can show this screen again from a menu. Reading another issue listed, I can start the activity from my SplashScreen, and start my home screen when done.

But, when I forced show the WelcomeScreen, there is no way to know if it's forced show or not, and the activity was started again.

I achieved a way to do this, creating a shared preference and ignore the startActivity if it has the key, but I would like to know if is it possible to have a key or a property that flags the activity was forced shown or not.

The code from my done button (get the reference from yours button using butterknife)

@OnClick(com.stephentuso.welcome.R.id.wel_button_done)
    public void mButtonDoneOnClickListener() {
        completeWelcomeScreen();

        if(!PreferenceManager.getDefaultSharedPreferences(MyWelcomeActivity.this).contains("intro"))
            startActivity(new Intent(MyWelcomeActivity.this, MainActivity.class));
    }

Text & Indicator Colors

How to change text(skip) and indicator color in bottom layout? (By default just White Color) Thanks

App crashes after the 16th screen

I'm using welcome-android to create a slideshow gathering all the things my wife loves.
There are 36 pages, and I'm using almost all page example model included in welcome-android.
Until now, I used only photo.png provided in welcome-android https://github.com/stephentuso/welcome-android/blob/master/sample/src/main/res/drawable/photo.png, and I could see the whole slideshow without any issue.

Now, I replace "photo.png" with resized photos/clipart (500x500px & transparent background), and here is my problem/issue : App crashes after the 16th screen.

Here is my logcat : http://pastebin.com/LfDkGTag

Testing welcome android in another project

I was looking up some documentation related to android testing and it was advised that if I am testing a library, I should open a new project and test the methods. Could that be incorporated into the github repo ? If so, how?

Thanks!

Hard coded strings

Hello Stephen Tuso.
Thank you for your awesome App.

The "issue" i want to report, is that all displayed text on the welcome screens is hard coded

Ex: https://github.com/stephentuso/welcome-android/blob/master/sample/src/main/java/com/stephentuso/welcomeexample/DefaultWelcomeActivity.java

.page(new TitlePage(R.drawable.ic_image_white, "Default Welcome Screen"))
                .page(new BasicPage(R.drawable.ic_style_white, "Default style", "No custom styles are applied to this welcome screen"))
.page(new BasicPage(R.drawable.ic_image_white, "Default properties", "No properties were set on the WelcomeScreenBuilder"))

So, I found how to expose these hard coded strings https://github.com/KowalskiOmniROM/welcome-android/blob/master/sample/src/main/java/com/stephentuso/welcomeexample/DefaultWelcomeActivity.java

Due of my lack of knowledge, I didn't figure how to expose:
https://github.com/stephentuso/welcome-android/blob/master/sample/src/main/java/com/stephentuso/welcomeexample/fragment/ExampleFragment.java
Toast.makeText(getContext(), "Button clicked in custom fragment", Toast.LENGTH_SHORT).show();

Anyway, thank you for your great work.
Have a nice day.

Preview fails because of dependency preference-v7:24.2.1 conflicting.

I am not sure how I will help you to reproduce it but I have support library version 25.1.0 and welcome:1.1.0.

I initially get this warning/error from Android Studio:

image

This crashed the preview with a stracktrace:

java.lang.NoSuchFieldError: ViewBackgroundHelper at android.support.v7.widget.AppCompatBackgroundHelper.loadFromAttributes(AppCompatBackgroundHelper.java:46) at android.support.v7.widget.AppCompatImageView.<init>(AppCompatImageView.java:63) at android.support.v7.widget.AppCompatImageView.<init>(AppCompatImageView.java:56) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:423) at org.jetbrains.android.uipreview.ViewLoader.createNewInstance(ViewLoader.java:441) at org.jetbrains.android.uipreview.ViewLoader.loadClass(ViewLoader.java:240) at org.jetbrains.android.uipreview.ViewLoader.loadClass(ViewLoader.java:195) at com.android.tools.idea.rendering.LayoutlibCallbackImpl.loadClass(LayoutlibCallbackImpl.java:193) at android.view.BridgeInflater.loadCustomView(BridgeInflater.java:333) at android.view.BridgeInflater.onCreateView(BridgeInflater.java:152) at android.view.LayoutInflater.onCreateView(LayoutInflater.java:717) at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:785) at android.view.BridgeInflater.createViewFromTag(BridgeInflater.java:222) at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:727) at android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:858) at android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:70) at android.view.LayoutInflater.rInflate(LayoutInflater.java:834) at android.view.LayoutInflater.inflate(LayoutInflater.java:492) at com.android.layoutlib.bridge.bars.CustomBar.<init>(CustomBar.java:95) at com.android.layoutlib.bridge.bars.NavigationBar.<init>(NavigationBar.java:52) at com.android.layoutlib.bridge.bars.NavigationBar.<init>(NavigationBar.java:46) at com.android.layoutlib.bridge.impl.Layout.createNavBar(Layout.java:284) at com.android.layoutlib.bridge.impl.Layout.<init>(Layout.java:140) at com.android.layoutlib.bridge.impl.RenderSessionImpl.inflate(RenderSessionImpl.java:301) at com.android.layoutlib.bridge.Bridge.createSession(Bridge.java:429) at com.android.ide.common.rendering.LayoutLibrary.createSession(LayoutLibrary.java:368) at com.android.tools.idea.rendering.RenderTask$2.compute(RenderTask.java:567) at com.android.tools.idea.rendering.RenderTask$2.compute(RenderTask.java:549) at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:863) at com.android.tools.idea.rendering.RenderTask.createRenderSession(RenderTask.java:549) at com.android.tools.idea.rendering.RenderTask.lambda$inflate$1(RenderTask.java:680) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)

When I remove the compile 'com.stephentuso:welcome:1.1.0' dependency from my build.gradle, everything is working again.

Is there any way we can bump up preference-v7 version to 25.1.0. I feel like that might fix the issue.

My apologies if this is not this libraries problem but as removing this dependency was a direct solution to the preview crashing, I thought I should report it here.

Love your work and appreciate all the hard work btw 👍.

layout_height not seted(Bug)

Hi. Thanks for great work.
When i use library iget the error Binary XML file line #30: You must supply a layout_height attribute. because of in wel_activity_welcome.xml layout_height of View not seted.

Its crashing on Vivo v1 device

android.view.InflateException: Binary XML file line #44: Error inflating class Button
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2338)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2390)
at android.app.ActivityThread.access$800(ActivityThread.java:151)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1321)
at android.os.Handler.dispatchMessage(Handler.java:110)
at android.os.Looper.loop(Looper.java:193)
at android.app.ActivityThread.main(ActivityThread.java:5292)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:824)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:640)
at dalvik.system.NativeStart.main(Native Method)
Caused by: android.view.InflateException: Binary XML file line #44: Error inflating class Button
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:713)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758)
at android.view.LayoutInflater.inflate(LayoutInflater.java:492)
at android.view.LayoutInflater.inflate(LayoutInflater.java:397)
at android.view.LayoutInflater.inflate(LayoutInflater.java:353)
at android.support.v7.app.AppCompatDelegateImplV9.b(AppCompatDelegateImplV9.java:284)
at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:140)
at com.stephentuso.welcome.ui.WelcomeActivity.onCreate(WelcomeActivity.java:42)
at android.app.Activity.performCreate(Activity.java:5264)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1088)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2302)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2390) 
at android.app.ActivityThread.access$800(ActivityThread.java:151) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1321) 
at android.os.Handler.dispatchMessage(Handler.java:110) 
at android.os.Looper.loop(Looper.java:193) 
at android.app.ActivityThread.main(ActivityThread.java:5292) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:824) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:640) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: android.content.res.Resources$NotFoundException: Resource is not a Drawable (color or path): TypedValue{t=0x1/d=0x7f02005f a=3 r=0x7f02005f}
at android.content.res.Resources.loadDrawable(Resources.java:2124)
at android.content.res.TypedArray.getDrawable(TypedArray.java:602)
at android.view.View.(View.java:3579)
at android.widget.TextView.(TextView.java:642)
at android.widget.Button.(Button.java:107)
at android.support.v7.widget.AppCompatButton.(AppCompatButton.java:61)
at android.support.v7.widget.AppCompatButton.(AppCompatButton.java:57)
at android.support.v7.app.AppCompatViewInflater.a(AppCompatViewInflater.java:109)
at android.support.v7.app.AppCompatDelegateImplV9.b(AppCompatDelegateImplV9.java:1013)
at android.support.v7.app.AppCompatDelegateImplV9.onCreateView(AppCompatDelegateImplV9.java:1072)
at android.support.v4.view.LayoutInflaterCompatHC$FactoryWrapperHC.onCreateView(LayoutInflaterCompatHC.java:44)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:684)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:755) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758) 
at android.view.LayoutInflater.rInflate(LayoutInflater.java:758) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:492) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:397) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:353) 
at android.support.v7.app.AppCompatDelegateImplV9.b(AppCompatDelegateImplV9.java:284) 
at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:140) 
at com.stephentuso.welcome.ui.WelcomeActivity.onCreate(WelcomeActivity.java:42) 
at android.app.Activity.performCreate(Activity.java:5264) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1088) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2302) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2390) 
at android.app.ActivityThread.access$800(ActivityThread.java:151) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1321) 
at android.os.Handler.dispatchMessage(Handler.java:110) 
at android.os.Looper.loop(Looper.java:193) 
at android.app.ActivityThread.main(ActivityThread.java:5292) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:824) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:640) 
at dalvik.system.NativeStart.main(Native Method) 

Trouble saving to SharedPreferences

I have a custom finish button which I want to save a bunch of strings to SharedPreferences before calling finish but for some reason it does not end up saving.

It'll save if I create an intent to launch another activity, however, with new WelcomeFinisher(WelcomeFragment_2.this).finish(); nothing gets saved.

I've tried SharedPreferece editor .commit(), adding a countdowntimer and also post handler but nothing seems to work for me.

`

Change done button's text ²

First of all, congratulations for making this excellent library. I would only like to ask if you could point any sample of code where you shows how can the done button's text be changed.

I saw this answer (#10) but I didn't figured out how the .theme works, and where should I place it. Thanks!

Blank screen when app is launched a second time

There is a blank screen that appears to be like the app is launched but hasn't any UI to display. Pressing back dismisses the app and one can navigate normally with device otherwise everything appears like the device has frozen, which is not the case but that there's an app running with no interface and appears transparent to the device screen. This happens when the app is launched the subsequent times from the very first time it is installed and launched. Please we need this issue fixed asap.

Change Done button text ?

hi, i am using your library it is working fine but i when user reaches to the last page i want to change the button text from "DONE" to "OK", i am not able to find any method in your library , please anyone guide me?

change description textsize

How could I change Description and Title TextSize? cause using different typefaces changes font size appearance.

Change text of buttons

Hey how I can change the text from buttons "done" and "skip"
I not found method for do this, please help me

Clean up API and refactor

  • Add prefixes to resources to avoid naming conflicts with clients, make some resources private
  • Remove deprecated methods
  • WelcomeScreenConfiguration and WelcomeScreenBuilder could be combined.
  • Are WelcomePage.OnChangeListener and OnWelcomeScreenPageChangeListener both needed? Yes
  • More refactoring?

Back Button Issue

When I click on Back button at that time welcome slider finish and next screen open.Not app close.

No static field view_pager of type I in class -

java.lang.NoSuchFieldError: No static field view_pager of type I in class Lcom/stephentuso/welcome/R$id; or its superclasses (declaration of 'com.stephentuso.welcome.R$id' appears in /data/app/com.dak42.chacuatool-2/base.apk)
                                                                          at com.stephentuso.welcome.ui.WelcomeActivity.onCreate(WelcomeActivity.java:45)
                                                                          at android.app.Activity.performCreate(Activity.java:6251)
                                                                          at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1108)
                                                                          at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2403)
                                                                          at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2510)
                                                                          at android.app.ActivityThread.-wrap11(ActivityThread.java)
                                                                          at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1363)
                                                                          at android.os.Handler.dispatchMessage(Handler.java:102)
                                                                          at android.os.Looper.loop(Looper.java:148)
                                                                          at android.app.ActivityThread.main(ActivityThread.java:5461)
                                                                          at java.lang.reflect.Method.invoke(Native Method)
                                                                          at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit

Configuration does not accept Color Library

I was trying to write a unit test for welcome screen, and before I do that, I try to make a welcome screen with the library. I was trying to change the code in the configuration as follow:

new WelcomeScreenBuilder(this).defaultBackgroundColor(Color.RED)

An error popped up:"Expect Resource of type color", even though Color is an inbuilt library in android studio. Maybe we can overload the function so that the Colo library can also be accepted.

Failed Resolution and Class Not Found in API 22 and 23 devices

java.lang.NoClassDefFoundError: Failed resolution of: Lorg/jacoco/agent/rt/internal_b0d6a23/Offline;
at com.stephentuso.welcome.WelcomeHelper.$jacocoInit(WelcomeHelper.java:0)
at com.stephentuso.welcome.WelcomeHelper.(WelcomeHelper.java:25)
at com.stephentuso.welcomeexample.MainActivity.onCreate(MainActivity.java:38)
at android.app.Activity.performCreate(Activity.java:6285)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1108)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
at android.app.ActivityThread.access$900(ActivityThread.java:150)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
Caused by: java.lang.ClassNotFoundException: Didn't find class "org.jacoco.agent.rt.internal_b0d6a23.Offline" on path: DexPathList[[zip file "/data/app/com.stephentuso.welcomeexample-1/base.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_dependencies_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_0_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_1_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_2_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_3_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_4_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_5_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_6_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_7_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_8_apk.apk", zip file "/data/app/com.stephentuso.welcomeexample-1/split_lib_slice_9_apk.apk"],nativeLibraryDirectories=[/data/app/com.stephentuso.welcomeexample-1/lib/arm, /vendor/lib, /system/lib]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
at java.lang.ClassLoader.loadClass(ClassLoader.java:511)
at java.lang.ClassLoader.loadClass(ClassLoader.java:469)
at com.stephentuso.welcome.WelcomeHelper.$jacocoInit(WelcomeHelper.java:0) 
at com.stephentuso.welcome.WelcomeHelper.(WelcomeHelper.java:25) 
at com.stephentuso.welcomeexample.MainActivity.onCreate(MainActivity.java:38) 
at android.app.Activity.performCreate(Activity.java:6285) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1108) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476) 
at android.app.ActivityThread.access$900(ActivityThread.java:150) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:148) 
at android.app.ActivityThread.main(ActivityThread.java:5417) 
at java.lang.reflect.Method.invoke(Native Method) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616) 

Unit testing

  • Local unit tests
  • Instrumentation tests
  • At least 80% coverage

Error: Execution failed for task ':library:generatePublicXml'. > A problem occurred starting process 'command 'bash''

After downloading the source and put it into Android studio i got that error.
Event Log:
13:09:40 Executing tasks: [:library:generateDebugSources, :library:generateDebugAndroidTestSources, :library:mockableAndroidJar, :library:prepareDebugUnitTestDependencies, :sample:generateDebugSources, :sample:mockableAndroidJar, :sample:prepareDebugUnitTestDependencies, :sample:generateDebugAndroidTestSources]
13:09:52 Gradle build finished with 1 error(s) in 14s 87ms

// Thank you

Cause a problen in Android O

All com.android.support libraries must use the exact same version specification (mixing versions can lead to runtime crashes). Found versions 26.0.0-alpha1, 25.3.1. Examples include com.android.support:animated-vector-drawable:26.0.0-alpha1 and com.android.support:preference-v7:25.3.1 less... (Ctrl+F1)
There are some combinations of libraries, or tools and libraries, that are incompatible, or can lead to bugs. One such incompatibility is compiling with a version of the Android support libraries that is not the latest version (or in particular, a version lower than your targetSdkVersion.)

is there method for changing the description text color

BasicPage has method for changing the header color

headerColor

for each page but it did not see method for changing the description text for each page. I know I can do via custom fragment however, it would be useful to be add to the library.

Return to the same Activity after finishing

Hi, thank you for this great library. I've been using it and everything is fine and the welcome screen looks perfect, the only thing I don't understand is how to go back to the main layout after showing the welcome screen.

My MainActivity:

@Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        sampleWelcomeScreen = new WelcomeHelper(this, WelcomeActivity.class);
        sampleWelcomeScreen.show(savedInstanceState);
}

@Override
    protected void onSaveInstanceState(Bundle outState) {
        super.onSaveInstanceState(outState);
        sampleWelcomeScreen.onSaveInstanceState(outState);
    }

// If this method should display toast at the end or cancel the welcome screen, it is not doing so
@Override
    public void onActivityResult(int requestCode, int resultCode, Intent data) {
        if (requestCode == REQUEST_WELCOME_SCREEN_RESULT) {

            if (resultCode == RESULT_OK) {
                Toast.makeText(getApplicationContext(), "Completed (RESULT_OK)", Toast.LENGTH_SHORT).show();
//this Toast is not displayed
            } else if (resultCode == RESULT_CANCELED) {
                Toast.makeText(getApplicationContext(), "Canceled (RESULT_CANCELED)", Toast.LENGTH_SHORT).show();
//this Toast is not displayed
            }
        }
    }

I want you to end or click on "done" to display activity_main again

Binary XML file line #30: You must supply a layout_height attribute.

Just by following your basic tutorial of the README.md the app is crashing when started.

Caused by: android.view.InflateException: Binary XML file line #30: Binary XML file line #30: You must supply a layout_height attribute.

Seems like inflating R.layout.wel_activity_welcome is not working. When I look at the code there is no height attribute for the View at line #30

Show only on first run

Hi. thanks for great work.
How can i show welcome Activity only in first run and show MainActivity in next runs.

how to access Done button

hey! this library is really great.. i have been using it lately and i need to override done button, could you help me if there is any possible solution to it.

I tried to do it like this
public class MyWelcomeActivity extends WelcomeActivity
{
@Override protected WelcomeScreenConfiguration configuration()

{ DoneButton done = new DoneButton(findViewById(R.id.button_done)); done.setOnClickListener(new View.OnClickListener() { @Override
public void onClick(View v) { Log.e("SahajLOG", "Done Button Called "); completeWelcomeScreen(); } });
return new WelcomeScreenBuilder(this) .theme(R.style.CustomWelcomeScreenTheme) .defaultTitleTypefacePath("Montserrat-Bold.ttf") .defaultHeaderTypefacePath("Montserrat-Bold.ttf") .titlePage(R.drawable.traffic_sign, "Welcome", R.color.SwipeScreen1) .page(new WelcomeFragmentHolder() { @Override protected android.support.v4.app.Fragment fragment() { return new WelcomeProfileFillFragment(); }
}, R.color.material_green) //.swipeToDismiss(true) .build(); }
}

How to align title and description to the center of the fragment as in demo gif

I tried to find a configuration option to set the alignment but I was unable to find it. How do I set the text align to center. By default the text aligns to the left

public class WelcomeScreenActivity extends WelcomeActivity {
    @Override
    protected WelcomeConfiguration configuration() {
        return new WelcomeConfiguration.Builder(this)
                .defaultTitleTypefacePath("Montserrat-Bold.ttf")
                .defaultHeaderTypefacePath("Montserrat-Bold.ttf")

                .page(new BasicPage(R.drawable.ic_front_desk_white,
                        "Welcome",
                        "An Android library for onboarding, instructional screens, and more")
                        .background(R.color.orange_background)
                )

                .page(new BasicPage(R.drawable.ic_thumb_up_white,
                        "Simple to use",
                        "Add a welcome screen to your app with only a few lines of code.")
                        .background(R.color.red_background)
                )

                .page(new ParallaxPage(R.layout.parallax_example,
                        "Easy parallax",
                        "Supply a layout and parallax effects will automatically be applied")
                        .lastParallaxFactor(2f)
                        .background(R.color.purple_background)
                )

                .page(new BasicPage(R.drawable.ic_edit_white,
                        "Customizable",
                        "All elements of the welcome screen can be customized easily.")
                        .background(R.color.blue_background)
                )

                .swipeToDismiss(true)
                .exitAnimation(android.R.anim.fade_out)
                .build();
    }

    public static String welcomeKey() {
        return "WelcomeScreen";
    }
}

Several welcome activity launched when rotating

When you rotate the screen during the welcome screens (i.e. before you press "Done") , you'll end up with several identical welcome activities started.

That basically means that when you finish the welcome steps, you'll see a new welcome guide until you remove all the stacked welcome activities.

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.