Android Tutorial [B4X] Creating a cross platform custom view packed as b4xlib

Discussion in 'Tutorials & Examples' started by Erel, Jul 24, 2019.

  1. Erel

    Erel Administrator Staff Member Licensed User

    The attached b4xlib library is a cross platform list of colors:

    [​IMG]

    It is a XUI custom view. The custom view is based on two layout files. One for xCustomListView and another one for the items layout.
    There is also a text file with the colors values.
    As layout files files are platform specific we need to create a layout file for each platform.

    Notes & tips:

    - The source code is included inside the b4xlib file (it is a zip file).
    - Layout files of other platforms will not be added to the project.
    - It is not possible to load layouts from DesignerCreateView without calling Sleep(0) before.
    - ListTemplate layout was actually taken from XUI Views.
    - A more powerful color picker implemented as a dialog is included in XUI Views.

    ColorsListProject.zip - The B4A project I've used to implement the view.
    ColorsList.b4xlib - The library with the files. Open it as a zip file to see.
    Usage Example - B4J project that uses this view.
     

    Attached Files:

    luke2012, jmon, Watchkido1 and 11 others like this.
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice