Android-based Mappwidget implementation of hand-drawn maps (iii)-Environment building

Source: Internet
Author: User

The following content is translated from: Environment Setup

First, you create a new project in the Eclispe development environment, and then you can integrate the project into your app project through the ECLISPE Project management tool. The following manual will teach you how to create a map object correctly.

First: Create a new Anroid project

Second: (attention to project details)

Set the project name

Check if the "Create New project in Workspace" radio button is selected

Select "Build Target"

Check and name "Create activity"

Set "Min SDK version"

Note: There is no translation of the button or noun in the eclispe, whether the English version of the Eclispe or the Chinese version of Eclispe, we should be able to read.

   

Third: Create a new "Libs" folder and put "Mapwidget_.jar" inside

: Http://pan.baidu.com/s/1bnFcOu7 Extract Code: a89r

Right-click the jar package and select "Add to Build Path"

In this way,you can see the "Mappwidget_1.2.0.jar" that you just added in "Refere nced Libraries"

IV: (can be skipped) attached mappwidget Javadoc. can go to see "How to Attach Javadoc" "This article to be translated ..."

Five: Copy the map tiles to the Assets folder, where the map tiles can be generated by the online tool, this piece of content can be viewed "How to create Map assets" This translation ... "

Sixth: In the "Res/layout" folder, open the Main.xml file in the source file view, add the following element property in the root directory LinearLayout

android:id= "@+id/mainlayout"

Seventh: Open the main class and paste the following code under OnCreate:

Mapwidget map = new Mapwidget (This, "map");

LinearLayout layout = (linearlayout) Findviewbyid (r.id.mainlayout);

Layout.addview (map);

  Eighth: Run this Android app.

Enclosed source code: HTTP://PAN.BAIDU.COM/S/1MGL6D40 Extract: 3eda

Android-based Mappwidget implementation of hand-drawn maps (iii)-Environment building

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.