Discussion Forums  >  Uncategorized

Replies: 15    Views: 686

Everest11
Code is Art
Profile
Posts: 195
Reg: Apr 04, 2011
GA, USA
1,950
04/06/11 11:13 AM (14 years ago)

Screen view going blank when returning from another view

Issue: Screen background on my last tab (which is a podcast) will turn white if I tap on another tab and then tap on the podcast tab again. This is what I am getting from both the simulator and on the devices: BT_fileManager: File does exist in Xcode bundle: blank.png 2011-04-06 13:48:07.130 lighttravelebook[74435:207] BT_background_view: Image for background view exists in Xcode bundle - not downloading. 2011-04-06 13:48:07.130 lighttravelebook[74435:207] BT_background_view: setImage 2011-04-06 13:48:13.822 lighttravelebook[74435:207] BT_screen_audio: viewWillAppear 2011-04-06 13:48:13.824 lighttravelebook[74435:207] BT_screen_audio: viewDidAppear
 
Everest11
Code is Art
Profile
Posts: 195
Reg: Apr 04, 2011
GA, USA
1,950
like
04/06/11 11:14 AM (14 years ago)
this is v1.5 by the way.
 
Everest11
Code is Art
Profile
Posts: 195
Reg: Apr 04, 2011
GA, USA
1,950
like
04/06/11 11:51 AM (14 years ago)
update: it seems like the podcast background is mimicking whatever the previous tab background is set to (white, black or an image)
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
04/06/11 11:26 PM (14 years ago)
Gets confusing eh' Back-n-forth between tabs and screens is even tough to explain. I think I understand what you mean. Try this... setup a few 'dummy' screens for your tab home screens. Just something simple like a URL screen with Google or something. Next... create one Home screen (for any of the tabs) that is a list menu. In this list menu... add items to load each of the screens you're asking about. So, you may have a menu with two items... Podcast and Other Podcast, or whatever your loading. Test this and see if the backrounds in on the Podcasts behave as expected... I think they will. Remove your test screens when you done. The idea is that we are trying to see if the backgrounds work as expected when they are NOT set as home screens for tabs. If they do, we have a tab-background issue that we'll need to fix...if they don't...um... I'll keep thinking ;-) I think what's happening is that the tabs don't reload the screen when their tapped and the background isn't getting 'rebuilt' because of it. Each screen needs to totally re-build it's background when it's displayed so it doens't inherit the previous screens configuration. It may not be happening on a tab-action
 
Everest11
Code is Art
Profile
Posts: 195
Reg: Apr 04, 2011
GA, USA
1,950
like
04/07/11 12:15 AM (14 years ago)
Hey David, I will give it a try. It was driving me crazy all day (as well as getting the No Screens error).
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
04/07/11 12:29 AM (14 years ago)
Forgot about the no-screens error. For that... lets try to debug by doing this... a) On your compuer, find where the simulator stores it's downloaded files. On my machine it's... /Users/davidbook/Library/Application Support/iPhone Simulator/4.2/Applications/APP ID/Documents b) Remove EVERYTHING from the documents directory. This makes sure nothing is 'cached' (cached files go here on the sim) c) Open the BT_config.txt file in the xCode project. Try not to freak out... looks scary... it's not. Find the dataURL value. It's a very very long URL leading to your buzztouch control panel (unless you changed it). Don't worry about the URL itself... but DO change the name of the dataURL entry. Change it to something random, like dataURL9999 The idea here is that we are tricking the app into thinking dataURL doesn't exist (it doesn't, you change it's name). d) Compile and run, see what happens. This approach will FORCE the app to use the configuration data in the project instead of trying to download a new copy from the dataURL (because dataURL doesn't exist anymore). If it loads fine, we'll know something's breaking with the newly downloaded config data. If it doesn't run, we'll look the broken config data in the BT_config.txt. Hope this isn't too confusing. Recap... a) delete cache b) Rename dataURL to dataURL999999 c) launch (always open console to see some hints)
 
Everest11
Code is Art
Profile
Posts: 195
Reg: Apr 04, 2011
GA, USA
1,950
like
04/07/11 12:54 AM (14 years ago)
No, not confusing at all. I noticed the config file was never updating and I had to manually download and put the file in the project. On another subject I uploaded the app to ITC after validating and got this error...com.apple.transporter.util.StreamUtil.readBytes(Ljava/io/InputStream;)[B Don't you love troubleshooting errors?!!
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
04/07/11 01:24 AM (14 years ago)
I removed your previous post so your App Id and API Key didn't show ;-) Your not alone on the first issue, the Stream Util thing...see this: http://blog.saers.com/archives/2011/04/04/solution-for-com-apple-transporter-util-streamutil-readbytesljavaioinputstreamb/ Second: OK, good, the app runs without downloading from the control panel. This means something screwy with the download. Put the dataURL back (remove the 9999) and launch it. It will try to download / save the config file. First see if it's downloading and saving to the cache directory. If it is, we'll need to look at it and see what's happening. It's not as hard as it sounds ;-) See if it downloads to the cache folder.
 
Everest11
Code is Art
Profile
Posts: 195
Reg: Apr 04, 2011
GA, USA
1,950
like
04/07/11 01:37 AM (14 years ago)
I am assuming it did download something since there are 4 files in the cache directory.
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
04/07/11 01:43 AM (14 years ago)
Cool. Forgot to mention... it's the cachedAppConfig.txt file. Kindly send it to info 'at' buzztouch.com as an attachment with the app name in the subject line. I'll get it figured out. May be in the morning (I'm super beat) but I'll get it. Nudge this post if you don't see a re-post by me but noon-ish tomorrow. (PST)
 
Everest11
Code is Art
Profile
Posts: 195
Reg: Apr 04, 2011
GA, USA
1,950
like
04/07/11 01:46 AM (14 years ago)
hmmm...All I see is a Appmodified.txt and some screendata files
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
04/07/11 01:58 AM (14 years ago)
This is interesting. I'll be it's related to the StreamUtil.readBytes issue. Puzzling. I'm surprised the console doesn't say 'error downloading' or 'error saving' or something? If you empty that directory, then launch the app, then tap NO menu items, the only files you'll see are the screen-data files for each of the home screens for each tab. You may not even see all of those, depending on the screen type. Each screen downloads and saves a file for offline use and not all tab-home-screens fetch their data until the tab becomes active for the first time. Lets first try to get the Stream.util.readBytes thing fixed. For sure an xCode / iOS problem (from the reading I've done). It's weird that a screen could download and save a file but the main configuration file is not downloading and saving. It's all plain-text and the routine that runs is the same for the main file as it is for the config file. You're sure the dataURL is still dataURL (case senstive) right? I'll check this post in the AM.
 
Everest11
Code is Art
Profile
Posts: 195
Reg: Apr 04, 2011
GA, USA
1,950
like
04/07/11 01:55 PM (14 years ago)
Hey David, yes the dataURL is still the same: dataURL:http://www.buzztouch.com/appdata/v1.5.php?command=getAppData&appGuid=[buzztouchAppId]&apiKey=[buzztouchAPIKey] Also, since my certs expired this AM I am in waiting mode to get back going to try and validate and upload the app since my status has been Pending Revocation most of the day. Maybe the Stream.util.readBytes issue may have been related to the provisioning profile/certs expiring?
 
Everest11
Code is Art
Profile
Posts: 195
Reg: Apr 04, 2011
GA, USA
1,950
like
04/08/11 04:46 AM (14 years ago)
RESOLVED: StreamUtil issue. Ran sudo /Developer/Library/uninstall-devtools –mode=all in the terminal then reinstalled Xcode 4 & SDK which cleared up all the error messages I was receiving. Also, going back to the original screen issues...instead of loading the actual podcast on the home screen for the tab I added a sub screen to handle the audio streaming (which, by the way, seems to break easily if you use a URL to the file on a web server. I saw a lot of error loading audio messages so I just added the mp3 to the project). Now, when I go back and forth between tabs the podcast home screen background stays as I set it in the configuration. I did want to bring up one other thing regarding the config file. Should a new refresh data message pop up regardless if you are using a simulator or device? It seems to work 90% of the time on the simulator but maybe 10% on an actual device when testing.
 
David @ buzztouch
buzztouch Evangelist
Profile
Posts: 6866
Reg: Jan 01, 2010
Monterey, CA
78,840
like
04/08/11 08:41 AM (14 years ago)
The logic for the 'refresh pop up' works the same on the device and on the simulator. It's all about when it checks for updates. When it checks depends on what OS the device is running. For newer devices, that support multi-tasking, it will check for updates each time the app is 'brought to the forefront' On older devices, that don't support mutli-tasking, it checks when the app is launched. When the home button is pressed, the app is closed (on non-multi tasking devices). This behavior should not change from sim to device.
 

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.