wizbots / labtab

0 stars 0 forks source link

Add new menu entry Settings #108

Closed internetmosquito closed 5 years ago

internetmosquito commented 5 years ago

Add a new entry in main menu, call it Settings, before the logout option

screenshot_20190107-111340_labtab

For now, only show Wizbots version, which is impossible to see right now

internetmosquito commented 5 years ago

@kapoorutd This ain't working, getting this error while trying to fire up application

error: resource string/wizbots_version (aka org.wizbots.labtab:string/wizbots_version) not found.
Message{kind=ERROR, text=error: resource string/wizbots_version (aka org.wizbots.labtab:string/wizbots_version) not found., sources=[/home/internetmosquito/git/labtab/app/src/main/res/layout/fragment_settings.xml:12], original message=, tool name=Optional.of(AAPT)}

Seems related with this in the fragment

    <org.wizbots.labtab.customview.TextViewCustom
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_marginLeft="@dimen/extra_small_margin"
        android:gravity="center|left"
        android:text="@string/wizbots_version"
        android:textColor="@color/purple"
        android:textSize="@dimen/text_size_small"
        app:font="@string/font_pt_sans_narrow_regular" />

Please fix

internetmosquito commented 5 years ago

So I added missing part to strings.xml

<string name="wizbots_version">LabTab version is v1.8.5</string>

But then firing up the application noticed this

selection_796

I could see a fragment txt_version right next to the one that gets the above string, if I changed the visibility to hidden

selection_795

It works fine

selection_794

Why do we need that one in the first place?

kapoorutd commented 5 years ago

@internetmosquito txt_version is for version text and will not be hard coded, txt_version value will be given at run time, currently it is fetching value for app version name (that is 1.0, written in build.gradle) we can also create a constant for labtab tab version like base urls screenshot 2019-01-08 at 11 17 42 am and you have to change it every time whenever you update version name.

LabTab version is v1.8.5 is also works fine and you have to update version values in string file, but changing string.xml for every build is not consider as good practise. According to Android docs we should increase app version name and version code in app build.gradle ![screenshot 2019-01-08 at 11 28 47 am](https://user-images.githubusercontent.com/6163203/50812409-a347d180-1338-11e9-93af-765b3254e0dd.png) so we suggest whenever you create new build, change the app version name and version code in app level build.gradle and it will automatically reflect on setting page like below image ![screenshot 2019-01-08 at 11 32 21 am](https://user-images.githubusercontent.com/6163203/50812535-1a7d6580-1339-11e9-8fd7-034f8e3c46c3.png)
internetmosquito commented 5 years ago

@kapoorutd fine with me, then please update gradle file and let me know when it's ready

kapoorutd commented 5 years ago

@internetmosquito we implemented as requested, please test and close the issue if fixed

kapoorutd commented 5 years ago

@internetmosquito we implemented as requested, please test and close the issue if fixed

internetmosquito commented 5 years ago

This was released in 1.8.6