Discussion Forums  >  Plugins, Customizing, Source Code

Replies: 11    Views: 85

Njmpwnz
Apple Fan
Profile
Posts: 165
Reg: Feb 08, 2011
Cleves
2,350
07/17/12 12:54 PM (13 years ago)

Menu Button issue iOS

I am trying to get rid of extra scroll space on my button menu. This works on iPad: //grid if([buttonLayoutStyle isEqualToString:@"grid"] || [buttonLayoutStyle isEqualToString:@""]){ contentWidth = deviceWidth; contentHeight = ((boxHeight + labelHeight) * (numButtons + 10)) / buttonsPerRow - (deviceHeight * 1.5); if(contentHeight < deviceHeight) contentHeight = (deviceHeight + 50); self.myScrollView.frame = CGRectMake(0, 0, deviceWidth, deviceHeight); self.myScrollView.contentSize = CGSizeMake(contentWidth, contentHeight + 1000); But it leaves extra space on iPhone. Any ideas? thanks
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/17/12 01:20 PM (13 years ago)
Great post....subscribe
 
Njmpwnz
Apple Fan
Profile
Posts: 165
Reg: Feb 08, 2011
Cleves
2,350
like
07/17/12 05:24 PM (13 years ago)
is there a way i could do one for iPhone and one for iPad?
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/17/12 05:57 PM (13 years ago)
yes...in Xcode Go to Project>>Targets>>Summary Tab and then under "iOS Application Target" go to Devices and select the device you want to code for.
 
Susan Metoxen
buzztouch Evangelist
Profile
Posts: 1706
Reg: May 01, 2011
Hopkins, Minnes...
26,260
like
07/17/12 08:41 PM (13 years ago)
Does this code center the buttons on the screen? I would like to be able to center the buttons so they look good on both Android and iOS.
 
Njmpwnz
Apple Fan
Profile
Posts: 165
Reg: Feb 08, 2011
Cleves
2,350
like
07/18/12 07:37 AM (13 years ago)
unfortunately not.
 
Susan Metoxen
buzztouch Evangelist
Profile
Posts: 1706
Reg: May 01, 2011
Hopkins, Minnes...
26,260
like
07/18/12 08:03 AM (13 years ago)
I miss the menu with header in 2.0 so I am trying to make the buttons work out. But I would like all of my apps to work in Android and iOS as the same project in order to avoid dual maintenance. If someone could make a plugin for centered buttons and more options for sizes and margins, that would be so cool!
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/18/12 08:23 AM (13 years ago)
What we really need is a way to intagrate Storyboard into a Buzztouch iOS app. Then any and all button woes would be no more.... Getting your iOS app to compile in Eclipse without many issues....that would very useful.
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/18/12 08:25 AM (13 years ago)
Also is that code above for BTv2.0 or 1.5? Where do you paste it?
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/18/12 08:45 AM (13 years ago)
Also is that code above for BTv2.0 or 1.5? Where do you paste it?
 
Njmpwnz
Apple Fan
Profile
Posts: 165
Reg: Feb 08, 2011
Cleves
2,350
like
07/18/12 08:54 AM (13 years ago)
its 2.0. it's in the BT_screen_menuButtons.m right under //setup scroll view. It's size depends on the button layout int contentWidth = 0; int contentHeight = 0;
 
lsills81
Apple Fan
Profile
Posts: 469
Reg: Mar 19, 2012
location unknow...
14,090
like
07/18/12 09:54 AM (13 years ago)
@njmpwnz Thanks
 

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.