[OLD version][APP][dev] The Box v3- a lightweight app for custom ROM devs 12Aug2014

Search This thread

erikalin

Senior Member
Sep 4, 2012
1,062
2,906
Twin Cities, Mini Soda USA
I never attempted to create my own donation button within the PayPal site and use that htnl code... I just copied my donation link from XDA and pasted that in there.... but like I said I tested the link that I pasted inside note++ and it worked fine but once compiled I get a timed out page in PayPal. But here goes a copy of the apk. . You have already done so much for me taking time to make me this 2 button version I can't thank you enough to now take time to help with the PayPal link! Your a stand up XDA member helping like this...it's rare to find someone as the likes of you. I also help others out when ever approached on how to theme a certain aspect of a rom and pay it forward always.
No problem. I had time Tuesday. Won't have time today, but I'll get you within the next couple days. Stay tuned. I'll tag you when I post it. In the meantime, try what I said to create the link through PayPal. There are reasons that could work. I will check it out soon either way though. Peace.
 

erikalin

Senior Member
Sep 4, 2012
1,062
2,906
Twin Cities, Mini Soda USA
I never attempted to create my own donation button within the PayPal site and use that htnl code... I just copied my donation link from XDA and pasted that in there.... but like I said I tested the link that I pasted inside note++ and it worked fine but once compiled I get a timed out page in PayPal. But here goes a copy of the apk. . You have already done so much for me taking time to make me this 2 button version I can't thank you enough to now take time to help with the PayPal link! Your a stand up XDA member helping like this...it's rare to find someone as the likes of you. I also help others out when ever approached on how to theme a certain aspect of a rom and pay it forward always.


Alright, my friend. Finally got a second to test this. The solution is simple, and it's what I said. You were using the link from the XDA button, but that works through XDA. It's not a valid link on it's own. It works in your browser because you're logged into XDA. Open a clean browser (no temp files no cookies not logged in to xda) and paste that link, and it's going to give you the error you see in app. All you need is to get your own, direct paypal donate URL.

Solution: Create a donate button in paypal.

I just built this real quick with my own paypal link, just to show you what you'll have. I cannot make yours (or I would have done that for you), because you have to create the button's link in your own paypal account. Mine is just a demo.

So go to paypal maybe like here.
Choose "Create your button now"
And in the code box that you get, click the tab for "email" to get just the URL, as opposed to "website" which gives you html code for a form button. See attached screenshot.
Dat's it. Use that URL, my friend.
 

Attachments

  • box_sick_paypaldemo.apk
    672.2 KB · Views: 32
Last edited:

SICKMADE

Inactive Recognized Themer
Feb 11, 2013
2,390
5,242
42
LAS VEGAS "SIN CITY"
Alright, my friend. Finally got a second to test this. The solution is simple, and it's what I said. You were using the link from the XDA button, but that works through XDA. It's not a valid link on it's own. It works in your browser because you're logged into XDA. Open a clean browser (no temp files no cookies not logged in to xda) and paste that link, and it's going to give you the error you see in app. All you need is to get your own, direct paypal donate URL.

Solution: Create a donate button in paypal.

I just built this real quick with my own paypal link, just to show you what you'll have. I cannot make yours (or I would have done that for you), because you have to create the button's link in your own paypal account. Mine is just a demo.

So go to paypal maybe like here.
Choose "Create your button now"
And in the code box that you get, click the tab for "email" to get just the URL, as opposed to "website" which gives you html code for a form button. See attached screenshot.
Dat's it. Use that URL, my friend.

I appreciate the help it worked perfect! Here is a screen of my final version of The Box.... I have the note 4 for tmo and Lollipop should be out and when it finally gets released I will be able to use the standard version of The Box wirh 6 buttons being I don't want to waste my time making a new theme with the new update anytime now and all.... But I have something like 20+ themes now across the Samsung Galaxy and Note devices.... I love to theme so filling up those 6 boxes after the Lollipop update wont be hard lol. But again thank you! Man I had another question but I feel horrible asking after youve already helped so much... But you know the pop up window when pushing the menu button that says hi? Well is there a way of instead of adding the string to whatever is it possible on making it go to a webpage like my Facebook Theme Group? And if so since it doesn't have a drawable attached to it would I just enter the site into the string? And lastly I know and respect that the about is not to be touched being that you deserve credit for making and sharing this app for everyone to use.... But my question was would it be ok if well underneath your about after the link that takes you to this post would it be ok with you if I were to add a small about as well? I just want to let people know a few important facts about my themes and also what other devices i have themes for..... or other various things that may come up. If you would rather me not add a small about underneath yours I will totally understand and respect that but if you don't mind that would be awesome as well.
 

Attachments

  • Screenshot_2015-03-14-07-41-10_wwCnote320150314_074216.jpg
    Screenshot_2015-03-14-07-41-10_wwCnote320150314_074216.jpg
    108.6 KB · Views: 110
  • Screenshot_2015-03-14-08-39-15_rfunote320150314_084018.jpg
    Screenshot_2015-03-14-08-39-15_rfunote320150314_084018.jpg
    80.8 KB · Views: 108

erikalin

Senior Member
Sep 4, 2012
1,062
2,906
Twin Cities, Mini Soda USA
I appreciate the help it worked perfect! Here is a screen of my final version of The Box.... I have the note 4 for tmo and Lollipop should be out and when it finally gets released I will be able to use the standard version of The Box wirh 6 buttons being I don't want to waste my time making a new theme with the new update anytime now and all.... But I have something like 20+ themes now across the Samsung Galaxy and Note devices.... I love to theme so filling up those 6 boxes after the Lollipop update wont be hard lol. But again thank you! Man I had another question but I feel horrible asking after youve already helped so much... But you know the pop up window when pushing the menu button that says hi? Well is there a way of instead of adding the string to whatever is it possible on making it go to a webpage like my Facebook Theme Group? And if so since it doesn't have a drawable attached to it would I just enter the site into the string? And lastly I know and respect that the about is not to be touched being that you deserve credit for making and sharing this app for everyone to use.... But my question was would it be ok if well underneath your about after the link that takes you to this post would it be ok with you if I were to add a small about as well? I just want to let people know a few important facts about my themes and also what other devices i have themes for..... or other various things that may come up. If you would rather me not add a small about underneath yours I will totally understand and respect that but if you don't mind that would be awesome as well.
Glad you got your PayPal squared away. I'm glad to help, so ask questions anytime. If you want to add some "about your project" that's fine.

The "hi" is where a menu would go, which I've intentionally not built into The Box because I've tried to keep it simple to edit. It's easy for me to put a menu into an app, but it'll kill the easy, "make it yours" that I'm going for here for others to edit.

I'm in the process of relocating from the east coast to Mini Soda, and selling a house, and going to farewell parties, and doing this while working full time and flying back and forth every couple weeks ...

**********Future Changes**********

When I have time, I've planned to redo The Box...
 
Last edited:

erikalin

Senior Member
Sep 4, 2012
1,062
2,906
Twin Cities, Mini Soda USA
UPDATE! Sometime soon I am going to completely redo The Box in template form, for people to take and theme/mod/apktool for use in their own projects. Give me a couple weeks and I will start a new thread for it, but I'll post on this one to announce. Stay tuned.

For now, see how The Box For Wicked X ROM shaped up? You can check it out on the Play Store as a demo....
fv4dvoi.gif
 
  • Like
Reactions: bilgerryan

SICKMADE

Inactive Recognized Themer
Feb 11, 2013
2,390
5,242
42
LAS VEGAS "SIN CITY"
Man I'm diggin that box you got for Wicked... is there a template like that one posted or is that the updated one your referring to cause I really like that menu on the left so I can post all the devices I have themes for and then can use the 1 box app for all my themes
 

erikalin

Senior Member
Sep 4, 2012
1,062
2,906
Twin Cities, Mini Soda USA
Man I'm diggin that box you got for Wicked... is there a template like that one posted or is that the updated one your referring to cause I really like that menu on the left so I can post all the devices I have themes for and then can use the 1 box app for all my themes

Yeah, I want to make a template like the one I made for the Wicked X ROMs. I have to think about it, because I'm not exactly sure what you can edit in apktool. I can only put stuff in if you can edit it... I don't know. I will probably make one template that is detailed like The Box for Wicked X on the Play Store. Then, I will make a couple more simple template options. I think. Lol. Stay tuned. I will post on this thread when I get things together and ready to share.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 18
    **Wrong thread!** GO TO THE NEW THREAD FOR LATEST APP!​

    As of 24 May 2015 - find The Box v.4.0 here. Watch the youtube demo video in the OP For answers to most questions.

    Announcement: Can everyone who is using The Box in a ROM or theme collection project please post a link to your thread and a screenshot of your personalized layout of The Box?? I keep hearing that it's used in more places, and I've asked that you just let me know. Please do so. Thanks.
    The Box

    The simple app that any custom Android ROM developer or themer just might want to have…

    New! You can check out one ROM's implementation of The Box on the play store at the following link. This is only useful for users of that one ROM. It's their version of The Box. Here you can easily make your own version. The Box sample here: https://play.google.com/store/apps/details?id=com.erikalin.box1

    Want people to stop asking you for updates and mods you've already uploaded? Tired of thread clutter with people asking repeatedly for certain download links or theme threads? Include this lightweight app that gives your ROM/theme users instant access to your updates, fixes, themes, etc., as soon as you upload. No additional service setup is required. Keep using whatever file hosting service you already use (i.e. AndroidFileHost, Dev-Host,your own, whatever).

    From start to finish, I estimate it will take you 45-60 minutes to get this ready to go for yourself. This includes time for you to learn "what goes where". If you were to do it a second time, it would take ten minutes. You decompile the app, change a few strings, and make a few other XML edits, a few smali edits, and put in your own desired images and app icon. Build it up and you have a nice addition to your custom ROM or theme package. Minimum SDK is 11; app will work out of the box on any version of Android 3.0 +. There are some other apps, more complex than this one, for you to choose to integrate in your projects. The Box is intentionally simple.

    Demo video for an earlier version of The Box:​

    Written instructions for customizing – See Post #3 for step-by-step instructions on exactly where you need to make your edits.

    Downloads

    SIX BUTTON VERSION as shown here in the OP is attached to the OP
    TWO BUTTON VERSION is found here.

    Change Log
    V3.0 August 12, 2014
    - completely redid the layout
    - added space for smaller buttons
    - new package name to avoid conflict with Play Store

    V.2.0 June 12, 2014
    - restructured app to remove webviews; buttons now call browser, or forum-browser (i.e. Tapatalk) per user's default settings (faster, smoother)
    - thanks talkingmonkeys for requesting this change.

    V 1.0 initial release June 9, 2014

    Known Issues
    Do NOT upload your version to the play store. Don't do it. Users will get app updates to someone else's project, because it will have the same package name. Avoid.

    Contributor
    erikalin

    Latest version – 3.0
    Latest release date – August 12, 2014
    Created on – June 9, 2014

    FAQ
    See Post #2.

    VJzRRWo.png
    11
    Customizations Guide - rev. August 12, 2014​

    Reminder: Please leave my credits as-is and obviously don’t rename The Box. It is illegal for you to take this code and call it your own app. I am letting you customize and use The Box pretty much however you want. Just don't take my credit away, please. Other than that, let’s do this.

    DIRECTIONS​

    Download the latest version of The Box template from the OP.

    Decompile the app.
    ZLriEU1.jpg


    Edit strings.

    In res\values\strings.xml edit only the following values:

    Code:
        <string name="ROMtitle">"Awesome ROM Name Here"</string>
        <string name="ROMsubtitle">"subtitle for your ROM here ~  by yourname"</string>
        <string name="action_settings">Hi :)</string> <!-- This is what shows on pressing the menu button -->
        <string name="themes">Themes</string> <!-- This is in the middle of the screen - you might want to leave this or change it -->



    Replace images.
    cDN2iW9.jpg


    These placeholder images are in a zip file attached to the OP. Note: You can adjust the background transparency for behind the button images in res\layout\activity_main.xml. For each button you’ll want to modify the android: background entry for that image button from the default which is as shown below:

    Code:
    android:background="#[B][COLOR="Red"]33000000[/COLOR][/B]"

    Edit smali for buttons’ URL destinations.

    Specify the URLs for the websites you want each button to go to. To edit MainActivity.java in an app you can make the edits in:
    smali\com\erikalin\box3\MainActivity.smali

    Find the website URLs and replace them. They have obvious names so you can easily modify them to be your desired URLs. Do not touch anything in the MainActivity.smali file except to edit the URLs, or you will probably mess things up. Each URL is matched with a method with an obvious name. These are the methods, and you'll edit the URLs for each:
    goToRepo
    goToXDA
    goTobuttonA
    goTobuttonB
    goTobuttonC
    goTobuttonD
    goTobuttonE
    goTobuttonF

    Let me show you one example below. I will put in red what you would edit. Don't touch anything else. Just change the URLs.

    Code:
    .method public goTobuttonA(Landroid/view/View;)V
        .locals 1
        .param p1, "view"    # Landroid/view/View;
    
        .prologue
        .line 29
        const-string v0, "[U][B][COLOR="red"]http://google.com/#q=letter+A[/COLOR][/B][/U]"
    
        invoke-direct {p0, v0}, Lcom/erikalin/box3/MainActivity;->goToUrl(Ljava/lang/String;)V
    
        .line 30
        return-void
    .end method



    Build it back up, sign and test. Enjoy!
    9
    Frequently Asked Questions​

    What is the main purpose of The Box?
    Very simple: Include this app in your ROM and users can check for ROM updates, fixes, modifications, themes and whatever else you would normally link to in your thread. Use AHF or whatever you normally use for hosting, and just create a useful file structure for your uploads.This app can really save thread clutter with people asking for links to mods and updates. You can customize The Box one time and literally never have to touch it again.

    Do you have a sample of The Box that is in use already in a custom ROM?
    Yep. The Box is currently being used in several different ROMs and theme collection projects. One version is on the play store. Download it to check it out as a functioning example: https://play.google.com/store/apps/details?id=com.erikalin.box1

    How is The Box different from OTA Updater apps?
    Thanks for the question, @gcrutchr. The Box is much more simple than OTA updater apps. This is basic, lightweight, clean and will just always work. More features means more places to experience errors. The Box is not meant to compete with feature-rich updater apps. You can customize The Box one time and literally never have to touch it again.

    Who is The Box for?
    This is primarily for custom ROM developers who do not want to create an app from scratch. The other possible users are themers who offer a library of themes and updates, and cannot create an app from scratch. Just because you can theme an app doesn’t mean you can make one. If you know how to create an app from scratch then do that. ;) If not, theme this one for your own use.

    Who is this not for?
    *This* thread here is not for end users. The Box is useless until it has been customized for someone’s ROM or other project. If an end-user downloads The Box from this thread, he/she will be getting a fully-functional dummy app with placeholder images. The Box is also not for app developers who are good at what they do. One can make a much more complex and personalized app for one’s specific needs. This is intentionally simple in order to be quick, easy and universal.

    How long would it take me to customize The Box to use in my project?
    An hour maybe, or a little less? If you go back later to update again, it'll probably take five minutes to revise a link or something like that.

    Do you have default images?
    Yeah. I put a folder of the placeholder images in a zip file attached to the OP. Replace those with your own and drop them back into the template apk file.

    Can you tell me all the places I need to get in and edit to customize?
    Yes. See post #3.

    What permissions does the app require?
    This app only needs one permission: Full internet access.

    What permissions do I have to use this app?
    Take it, customize it and use it in your own projects. Please post a link on this thread to your project in which you're using The Box. You NEED to leave the “About” tab on the bottom of the main activity (screen) and you need to not edit my About activity string. There are no ads, no fees, no hidden costs or other obligations. Please leave my credit as-is and my app name as-is. Don’t remove the About. I made The Box and have offered it to you for you to customize and personalize. Let’s just not pretend you made it, mkay?

    So what can I not modify if I use The Box in my own project?
    Don’t remove the visibility of the About tab from the main activity (“main screen”) and don’t edit the string content of that activity, which is located in strings.xml file and works in the AboutActivity.java class file. Do not rename the app. These are my credits and need to stay. Change whatever else you want.

    Can you add in this feature or that feature?
    Doubtful. This is intentionally simple in order to be both lightweight and universal, and easy for you to customize too! If you want a more complicated app then by all means go make one. If you have light suggestions, consistent with a basic, universal app such as this, feel free to make them on this thread. I’ll definitely consider all feedback, but offer no promises. This is supposed to be a SIMPLE solution.

    Why no splash screen?
    I see no reason to make end-users wait three seconds. It’s annoying. Nobody wants to be shown an ad when they open an app. They want to be shown an app. Also no facebook integration, ads, other device permissions or complicated programming which would just be harder for you to customize and thus defeat my purpose.

    What if I don't like this app?
    No problem, and I respectfully ask that you not share that with me. Just don't use it. I'm not seeking critique but sharing my work for free.

    If you have any questions, ask them in the thread and I’ll add to this FAQ post.​
    3
    Nice job, my friend. When you get a chance, post a screenshot and link to your ROM. I'll highlight your work in the OP.

    Sent from my U.S. Verizon HTC One M8 using Tapatalk.

    Sure :)

    First off I want to give some thanks to @cbucz24 as he started the process and got some images around/spiffed up :)

    This was all done for my little mess of a project that can be found here - it's called Tweaked (for better or worse) and has been my fun learning project for a couple years now across a few phones (currently an N900T Note3).

    Here's a screenshot of what the end result looks like:
    Screenshot_2014-09-08-00-48-27.png


    I made a few small changes here and there, mostly just to learn-by-doing and what not. It took a bit, but to avoid boring w/ details I added in an Info button/section (all I did was copy the thanks portion of my OP into it really lol), and I set it up so that when clicking on any of the 6 bottom buttons a small informational toast will also appear that describes the link as being a theme or kernel, the name of the OP, and the name of the theme/kernel (thought this would make it look cleaner then adding text descriptors but still offer the info... and I just wanted to play with adding toasts).

    Thanks again to @erikalin for putting a simple-to-use-and-mod base apk together!
    3
    The Box v.3.0 is up!

    The OP has the latest template to download, and the guide has been updated and simplified. It's much better... check it out. Don't use previous versions. Remember, if you use The Box in your project, please post a link to it in this thread. Cheers. Enjoy!

    Screenshot of the template (with placeholder images)
    VJzRRWo.png


    To check out a working copy of this app, see The Box for Wicked on the play store here: https://play.google.com/store/apps/details?id=com.erikalin.box1