Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Warning

This section is still WIP!

Table of Contentstoc
maxLevel3
minLevel3

Prerequisites 

  1. Download and install Android Studio.

    Info

    For more information, see installing Android Studio.

  2. WSO2 EMM supports API levels 16 to 23. Therefore install the Android API levels 16 to 23 on Android Studio.

...

Changing Android app catalog related logos and icons

  1. Clone the product-mdm emm repository. The folder will be referred to as <PRODUCT_EMM> throughout the documentation.

    Code Block
      git clone https://github.com/wso2/product-emm
  2. Navigate to the <EMM_AGENT_ANDROID><APP_CATALOG>/app/src/main/res directory.

    Info

    <EMM<APP_AGENT_ANDROID>CATALOG> refers to the <PRODUCT_MDM>EMM>/modules/mobile-agents/android/clientappcatalog file path.

    1. Navigate to the drawablemipmap-xxhdpi/ folder and change the following:Change the ic_launcher.png ( 144px X 144px ) file in order to change the icon. For more information, go to the Android icon guide.
      Image Modified
    2. Change
    3. Navigate to the mipmap-xxhdpi/ folder, and change the following file logos in order to change the header logos:

    4.  
    5. ic_logo.png  ( 240px X 72px ) Image Modified
      repeat_bg.png   ( 277px X 125px ) Image Modified
    6. Navigate to the drawablemipmap -xhdpi/ folder.Change , and change the ic_launcher.png ( 96px X 96px ) file to change the application icon.
    7. Change the Navigate to the  drawable-xhdpi/ folder, and change  the ic_logo.png (160px 267px X 48px), ic_logo_darker.png  (160px X 48px) and repeat_bg.png (222px X 100px)  file file in order to change the logos.
    8. Navigate to

      the drawable

      the mipmap-hdpi/

       folder.
      Change the 

      folder, and change the ic_launcher.png

       

      (72px X 72px) file in order to change the icon.

    9. Change the 

      Navigate to the drawable-hdpi/ folder, and change the ic_logo.png

       

      (

      120px

      200px X 36px),

      ic_logo_darker.png  (120px X 36px) and 

      and repeat_bg.png

       

      (122px X 55px) files in order to change the logos.

    10. Navigate to the

      drawable

      mipmap-mdpi/ folder

      .
      Change the 

      , and change the ic_launcher.png (48px X 48px) file to change the icon.

    11. Change

      Navigate to the drawable-mdpi/ folder, and change the ic_logo.png

       

      (

      80px

      133px X 24px)

      and ic_logo_darker.png  (80px X 24px) files

       file in order to change the logos.

  3. Open the client app-catalog folder that is in the <EMM_SOURCE_HOME>/modules/mobile-agent/android directory via Android Studio.
  4. Build the project to create a new APK with the changes.

    Info
    Expand
    titleClick here for more information on building the project.
    Note

    Support for the Android Developer Tools (ADT) in Eclipse is ending. Therefore, you should migrate the app development projects to Android Studio. For more information on transitioning to Android Studio, see Migrating to Android Studio.

    1. Get a GIT clone of the Android Agent application from GitHub.

    2. Update the Android Software Development Kit with the following:

      • SDK Versions 23 and 16. 

      • Build Tools Version 22.0.1.

      • Install or update Android Support Library.

      • Install or update Google Play Services.

      • Install Google USB Driver, if you are on a Windows platform.

    3. By default, the Android agent communicates with the server through http. For production, this needs to be changed to https, by configuring the following parameters in the Java class named Constants.java,which is in the org.wso2.EMM.agent.utils package: SERVER_PORT and SERVER_PROTOCOL.

      Anchor
      step3
      step3

      Panel

      For more information see below:

      Expand
      titleGenerating a BKS File

      Include Page
      Generating a BKS File for Android
      Generating a BKS File for Android

    4. Import the project on Android Studio, clean and build the project.

    5. Run the project on a device.

      Info

      The .apk file can be found in the <EMM_HOME>/repository/deployment/server/jaggeryapps/emm-web-agent/units/asset-download-agent-android/public/asset directory.

  5. Rename the created.apk file to android-agent.apk.
  6. Copy the renamed file and replace it instead of the existing android-agent.apk. file that is in the <EMM_HOME>/repository/deployment/server/jaggeryapps/emm-web-agent/units/asset-download-agent-android/public/asset directory

    Publish the built APK to your app store via the WSO2 App Manager publisher.

    Info

    For more information, see Creating an Android Application.