Stay on top of what's happening with OfferWorld.in | Like OfferWorld on Facebook | Follow @offer_world on Twitter


http://www.gearbest.com/promotion-merry-christmas-special-308.html
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[-]
Our Blog


[-]
Industry News
OUKITEL U15S super screenshot & fingerprint func...
Last Post: Carlos Barreira
11-30-2016 06:11 PM
» Replies: 0
» Views: 23
Bluboo Picasso 4G Confirmed with NFC Support
Last Post: manisha
11-26-2016 10:22 AM
» Replies: 2
» Views: 205
Chuwi First HiBox-hero Mini PC is Coming Soon
Last Post: rjainbwr
11-25-2016 10:04 AM
» Replies: 0
» Views: 169
OUKITEL U15S running 52 apps at the same time
Last Post: Carlos Barreira
11-23-2016 07:00 AM
» Replies: 0
» Views: 106
Oukitel U20 Plus releases first Dual Camera Smar...
Last Post: Carlos Barreira
11-23-2016 05:39 AM
» Replies: 0
» Views: 117

Easy process of Change Package Name in Android
#1
Lightbulb 
Easy process of Change Package Name in Android (Motodev / Eclipse)

Changing your project package in Motodev Studio or Eclipse is always tricky and takes time to master. We’ll continue with our previous example of Re-ordering a list and modify its package name. The package name we used in this project was “com.movivation.reorderingdemo”. Let’s start Motodev Studio for Android 3.1 and begin this journey.
 
[Image: 1_default_package1.png]
Now, we’ll be changing it to look like “com.movivationlabs.reorderingdemo”.
 
[Image: 2_change_package_refactor_rename.png]
To change the name of your package, right click on package name, then select “Refactor” -> “Rename” as shown in the above image. After clicking “Rename”, you’ll see a window that resembles like this :
 
[Image: 3_rename_dialog.png]
After changing the package, this window will look like :
 
[Image: 4_package_changed_rename_dialog.png]
On clicking the “OK” button on this dialog, Motodev Studio for Android processes your requirement to change the package name. The process takes a minute second to complete and you can see the changes here :
 
[Image: 5_package_change_explorer.png]
The first step of changing the package name is now completed. The next step is to change the package name using Android Tools found in the IDE. Right-click the “Project Name” in Project Explorer window, then click on “Android Tools” and at last click on “Rename Application Package”.
 
[Image: 6_android_tools_change_package.png]
On clicking that menu item, opens another dialog asking for new package name:
 
[Image: 7_rename_application_package.png]
The same dialog after changing the package name, the dialog looks like:
 
[Image: 8_package_renamed.png]
On affirming the changes, the IDE shows a very informative, line-by-line view of all the files that will be changed, and asks for final confirmation:
 
[Image: 9_name_change_comparison.png]

Clicking the “Finish” button starts the making the changes in all the mentioned files and finally the IDE asks for us to update the launch configuration:
 
[Image: 10_configuration_change.png]
This concludes the second step in changing the package. Now, all the files such as java source codes and Android manifest will be containing the newly proposed package. Look at the manifest file:
 
[Image: 11_change_package_android_manifest.png]

Our Re-ordering demo project was very small project with only one activity and a layout and that layout too, didn’t have any custom controls or UI controls that we extend in our project. The problem with Motodev and, in turn, Eclipse is that if we were to extend a UI control object, then the respective IDE won’t be able to modify the package name in the extended UI control object.
Below is the extended ImageView control named “TouchImageView”:
 
[Image: 13_custom_ui_object.png]
This control is not used in our project, I’ve shown this control only to make you understand that we need to modify package names for any custom control we use. This is the final step in changing the package name of an Android project.
In summary,
Refactor-rename the android package name.
Rename the package name using Android Tools.
Manually change the package in Android manifest or any other custom controls, styles, themes you’ve used in your project, if not changed otherwise.


Reply
Thanks given by:
http://www.gearbest.com/promotion-merry-christmas-special-308.html


Possibly Related Threads...
Thread Author Replies Views Last Post
  Can you give me advice to pick a smartphone around $100? SZ16FC 2 169 09-13-2016, 04:01 PM
Last Post: SZ16FC
  BlackView R7: the new flagship comes in May Carlos Barreira 0 680 04-16-2016, 05:53 AM
Last Post: Carlos Barreira
  NO.1 G4 a new SmartWatch with calling feature for $ 39.99 Carlos Barreira 0 172 04-16-2016, 05:09 AM
Last Post: Carlos Barreira
Lightbulb 5 Free Call Recorder Apps for Android Phone rjainbwr 0 202 04-08-2016, 12:14 PM
Last Post: rjainbwr
Lightbulb 5 Free Battery Saver Apps for Android rjainbwr 0 161 04-08-2016, 12:08 PM
Last Post: rjainbwr

Forum Jump:


Users browsing this thread: 1 Guest(s)
[-]
Latest Threads
Necklace Set Combo By Sanskruti only at Rs. 499/...
Last Post: charvi.promo
12-03-2016 05:42 PM
» Replies: 0
» Views: 21
ADS Trending Looks Make Up Combo With Ozomax Tra...
Last Post: charvi.promo
12-03-2016 05:39 PM
» Replies: 0
» Views: 23
24 Pc Dinner Set & Free Cartini 3 Pc Knife Set o...
Last Post: charvi.promo
12-03-2016 05:35 PM
» Replies: 0
» Views: 22
Trio 3G Android KitKat Phone only at Rs. 1999/-
Last Post: charvi.promo
12-03-2016 05:32 PM
» Replies: 0
» Views: 24
Celkon 4inch (10.16cms) Android Phone - A406 onl...
Last Post: charvi.promo
12-03-2016 05:29 PM
» Replies: 0
» Views: 19
LYF Water 8 Dual SIM Android Mobile Phone only a...
Last Post: charvi.promo
12-03-2016 05:24 PM
» Replies: 0
» Views: 20
LYF Earth 2 Dual SIM Fingerprint Sensor Mobile P...
Last Post: charvi.promo
12-03-2016 05:21 PM
» Replies: 0
» Views: 22
6 Lightweight Blankets By Azaani only at RS. 999...
Last Post: charvi.promo
12-03-2016 05:16 PM
» Replies: 0
» Views: 20
Fashion Fusion Large Soft 100% Twill Pashmina Sh...
Last Post: charvi.promo
12-03-2016 03:28 PM
» Replies: 0
» Views: 20
Ultra Cat Cushion, 28 cm only at Rs. 299/-
Last Post: charvi.promo
12-03-2016 03:15 PM
» Replies: 0
» Views: 20