Hello fellow xda users, I'm here again with another project, but this is slightly different from the many I post.
Here I will be teaching you Android enthusiast how to prepare and build/modify applications for your use or anyone's use.
I will have to admit I am still learning in this field of development but I would like to start this thread off now so I won't have to write out so much after I learn more.
So this means I will keep this thread going when I learn new tips, tricks and ideas. This way we can progress at the same level, and get to understand about Android development easier. And hopefully one day this thread could become a great resource thread for new Android developers and users.
[x] First off all, you will need your brain.
[x] Eclipse Studio (For building applications from scratch or source) - Here
[x] Apk Decompiler (Plenty of these are floating around xda) - Here
[x] Paint.NET/Photoshop (Used for editing images - .png and .9.png) - Paint.NET - Photoshop
[x] Notepad ++ (For editing code within the decompiled app - xml - class - dex) - Here
[x] JD GUI (For viewing and editing the .Java files( Src) without decrypting them. - Here
In Android/Programming, a source code is any collection of computer instructions written using some human-readable computer language. The source code of a program is specially designed to facilitate the work of computer programmers, who specify the actions to be performed by a computer mostly by writing source code.
The source code is often transformed by a compiler program into low-level machine code understood by the computer, this means you will not be able to read it, it will just appear as random symbols. The machine code might then be stored for execution at a later time. Alternatively, an interpreter can be used to analyse and perform the outcomes of the source code program directly on the fly.
Most computer applications are distributed in a form that includes executable files, but not their source code. If the source code were included, it would be useful to a user, programmer, or system administrator, who may wish to modify the program or understand how it works.
So I am assuming you have downloaded the Android SDK Bundle form the "What's Needed" section.
Here I will show you how to view any applications source code, this is really useful if you want to remove or add functions in an application.
Now this bit is far different from others on how they tell you to set it up, and it can be confusing for some. So I have taken then step to make make a .zip which contains everything needed to view the source code.
You can download this .zip from here. Extract the contents to your desktop using any unzipper (Winrar).
Now open Eclipse Studio from the SDK you just downloaded, and set a workspace (Leave it as it is). Once you're actually running Eclipse. Now the file you extracted to your desktop area (A2J) move that folder to your workspace. (C:\Users\yourcomputersname\workspace). When you have moved the "A2J" folder to your workspace. Close Eclipse and re open it. You should see a new project on the left project panel called "A2J".
Now download the applications source code that you want to view/edit and download it. The easiest way to download it is to go to the Play Store, search for the application, copy the URL, go to this site and then paste the URL in the site then download the .apk file.
Once downloaded, rename the "appsname.apk" to "app.apk" and then save it. Once saved, right click on it and click "copy", now head back into Eclipse and in the left panel, right click on "A2J" and click "paste". Then your app should appear in the project space, you may need to press the little arrow to view the files in that project.
Once the .apk is in there. Right click on "A2J" again and select "Run as" then select "Run Configurations" In the window, make sure the "Main Class" is set to "com.googlecode.dex2jar.v3.Main" if it isn't then copy that and paste it in that area. Now click "Arguments" change the "Program Arguments" to "app.apk". Then click "Run".
It will create a pop up telling you that there are some errors, click "Proceed" and wait till the command window at the bottom says "Done."
Once its done, right click on an empty space in the left project panel and click "Refresh". This will show you a "dex2jar" file under the "app.apk" file. Right click the ".Java" file and select "Copy". Once copied go to your desktop and select "Paste". Once pasted, extract the "JD GUI" .zip proved in the "Whats Needed" section to your desktop.
Then drag the ".Java" file onto the "jd-gui.exe" file. This will open a window. I personally find it annoying to edit/view the code form that application. So click "File" and then click "Save all sources". Save the file to your desktop. Extract the .zip and use "Notepad++" to view or edit the code.
More coming soon as I've exceeded my Data Limit. Again.
Shortly after the USA Unlocked and Developer Editions of the HTC One M8 received the … more
XDA Developers was founded by developers, for developers. It is now a valuable resource for people who want to make the most of their mobile devices, from customizing the look and feel to adding new functionality. Are you a developer?