S Stern0m1 Member Licensed User Feb 15, 2017 #1 When I set the activity theme to dialog the views from the layout file dont show. If I add them in code it works. Is that the way B4A was designed? Thanks
When I set the activity theme to dialog the views from the layout file dont show. If I add them in code it works. Is that the way B4A was designed? Thanks
Erel B4X founder Staff member Licensed User Longtime User Feb 16, 2017 #2 Maybe the activity size is zero at that point. Try to add a panel in your code and load the layout into the panel after you added the panel to the activity. Upvote 0
Maybe the activity size is zero at that point. Try to add a panel in your code and load the layout into the panel after you added the panel to the activity.
S Stern0m1 Member Licensed User Feb 21, 2017 #3 I dont think the activity size is zero as I get a blank screen. Any other ideas? I am setting the the theme to dialog in the manifest editor with: Code: Copy SetActivityAttribute(configuration,android:theme, "@android:style/Theme.Dialog") This is not the main activity. Could someone else try this and report back if the same thing happens? Thanks Upvote 0
I dont think the activity size is zero as I get a blank screen. Any other ideas? I am setting the the theme to dialog in the manifest editor with: Code: Copy SetActivityAttribute(configuration,android:theme, "@android:style/Theme.Dialog") This is not the main activity. Could someone else try this and report back if the same thing happens? Thanks
S Stern0m1 Member Licensed User Feb 21, 2017 #4 It loads only if #IncludeTitle: True , not if false. Is that by design or is that a bug? Thanks Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Feb 22, 2017 #5 Theme.Dialog is an Android 2 theme. I don't recommend you to use it. Your app will use the old Android 2 style and you will also encounter compatibility issue with newer devices. Upvote 0
Theme.Dialog is an Android 2 theme. I don't recommend you to use it. Your app will use the old Android 2 style and you will also encounter compatibility issue with newer devices.
S Stern0m1 Member Licensed User Feb 22, 2017 #6 How else can make an activity not full screen with the previous activity showing? Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Feb 22, 2017 #7 Why don't you use a regular panel? Upvote 0
S Stern0m1 Member Licensed User Feb 22, 2017 #8 I want to seperate it in a seperate activity. Thanks Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Feb 22, 2017 #9 You can implement all the code in a class and then reuse the class (like AnotherDatePicker for example). Upvote 0
You can implement all the code in a class and then reuse the class (like AnotherDatePicker for example).
S Stern0m1 Member Licensed User Feb 22, 2017 #10 Ok. Will try that. The dialog theme works fine on my Android 6.0. I have not done extensive testing. Are you sure that there will be issues on Androids greater than 2.0? I cant find any reference on Androids website that this theme won't work with newer versions. Can you provide a reference? Thanks Upvote 0
Ok. Will try that. The dialog theme works fine on my Android 6.0. I have not done extensive testing. Are you sure that there will be issues on Androids greater than 2.0? I cant find any reference on Androids website that this theme won't work with newer versions. Can you provide a reference? Thanks
S Stern0m1 Member Licensed User Feb 22, 2017 #11 Can you educate me a bit about themes in general? The code for a theme lies in the android it self? Its not fully contained in the App? Is there some part of the os that it needs? Trying to understand why it should make a difference which version Android. Thanks Upvote 0
Can you educate me a bit about themes in general? The code for a theme lies in the android it self? Its not fully contained in the App? Is there some part of the os that it needs? Trying to understand why it should make a difference which version Android. Thanks
Erel B4X founder Staff member Licensed User Longtime User Feb 23, 2017 #12 Theoretically it should work on all versions but it will use the Android 2 theme. Practically there are issues on some newer devices when you use the old themes. These themes are part of the OS. Upvote 0
Theoretically it should work on all versions but it will use the Android 2 theme. Practically there are issues on some newer devices when you use the old themes. These themes are part of the OS.