Discussion Forums  >  Plugins, Customizing, Source Code

Replies: 7    Views: 106

LA
Aspiring developer
Profile
Posts: 3280
Reg: Aug 16, 2012
Jerseyville, IL
42,900
11/06/12 02:02 PM (13 years ago)

Plugin Creator Code

I'm trying to figure the java part out on this and it seems a lot of info is already generated. Trying to figure out in the java code what to touch and what not to touch in Eclipse. For example, the code: //reference to base layout.. LinearLayout baseView = (LinearLayout)findViewById(R.id.baseView); Would I change the id.baseview to the R.id. mypluginname or leave this part alone? Any help would be appreciated and thank you in advance, LA
 
PSMDanny
Apple Fan
Profile
Posts: 1166
Reg: Dec 09, 2011
Heerlen
21,940
like
11/06/12 02:14 PM (13 years ago)
Hi LA, I have no experience with Android but refering to what I have seen for iOS you should leave all the code that is automagically generated untouched. You should add code to create a full functional plugin. My guess is that the code you are showing is the default code for setting up the screen (background image, navigationbar etc...) Hope this helps answering your question. Best Regards, Danny
 
LA
Aspiring developer
Profile
Posts: 3280
Reg: Aug 16, 2012
Jerseyville, IL
42,900
like
11/06/12 02:27 PM (13 years ago)
Hi @PSMDanny, Xcode and Eclipse, in my opinion, are like night and day. Totally different. The coding can be a hostile environment..lol.
 
PSMDanny
Apple Fan
Profile
Posts: 1166
Reg: Dec 09, 2011
Heerlen
21,940
like
11/06/12 02:34 PM (13 years ago)
Hi LA, I can't really tell about the difference because I haven't setup an Android environment but the plugin creator creates the files for iOS and for Android. If you load the newly created plugin into your project and run the app you'll see that you can create a new screen with the standard options like background color, background image etc. So the produced code must be almost identical (at least make the output the same). That's the reason I can tell that you should leave this in tact. Best Regards, Danny
 
LA
Aspiring developer
Profile
Posts: 3280
Reg: Aug 16, 2012
Jerseyville, IL
42,900
like
11/06/12 02:44 PM (13 years ago)
Yes of course the code is the same but connecting java and xml can be confusing. Thank you for the answer. What about the life cycle code? Do I leave one and start a new one or code within the generated code? LA
 
PSMDanny
Apple Fan
Profile
Posts: 1166
Reg: Dec 09, 2011
Heerlen
21,940
like
11/06/12 02:51 PM (13 years ago)
Hi LA, I'm sorry but I don't understand what you mean with "life cycle code". Just download the code that was generated by the plugin creator and start adding code into the files. I learned a lot of analyzing/comparing other plugins - how did they do it? So I recommend you do the same. Also sorry to say that I can't help you out with Android (maybe in the far, far, far future, haha) Best Regards, Danny
 
LA
Aspiring developer
Profile
Posts: 3280
Reg: Aug 16, 2012
Jerseyville, IL
42,900
like
11/06/12 03:04 PM (13 years ago)
Well lol not a lot of plugins for Android. I went back to basics with one button on my plugin and see what to do on the java file when that button is clicked. LA
 
PSMDanny
Apple Fan
Profile
Posts: 1166
Reg: Dec 09, 2011
Heerlen
21,940
like
11/06/12 03:06 PM (13 years ago)
Hi LA, Wish you all the luck!!! Happy coding ;-) Best Regards, Danny
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.