Latest Episode
Share This Page

Go Back   Keith and The Girl Forums Keith and The Girl Forums Talk Shite

Talk Shite General discussion

Reply
 
Thread Tools Display Modes
Old 05-21-2009, 01:15 AM   #361 (permalink)
Senior Member
 
Rufio's Avatar
 
Join Date: Aug 2008
Location: Texas but i go to school elsewhere
Posts: 498
so if u had to estimate, when should we expect the KATG app?

btw from what i've seen so far it looks pretty awesome
(Offline)   Reply With Quote
Old 05-21-2009, 02:16 AM   #362 (permalink)
Senior Member
 
hayroob's Avatar
 
Join Date: Mar 2008
Location: Detroitish
Posts: 1,561
Quote:
Originally Posted by Rufio View Post
so if u had to estimate, when should we expect the KATG app?

btw from what i've seen so far it looks pretty awesome
There is no way for me to say for sure. I've submitted twice and been rejected twice for totally different reasons. I think it'll be live by the end of June, but it's really not up to me.
(Offline)   Reply With Quote
Old 05-21-2009, 01:36 PM   #363 (permalink)
Senior Member
 
hayroob's Avatar
 
Join Date: Mar 2008
Location: Detroitish
Posts: 1,561
This is what the countdown looks like right now. I haven't made any logic to say that if the show is live to change the label to right now or whatever. This will come next.

Also it feels cluttered so I need to tinker with layout.

And as always every time I add something it gets a little slower so I think I need to stop adding features and tune for awhile, clean up the codebase, etc.
Attached Images
File Type: png IMG_0017.PNG (53.7 KB, 80 views)

Last edited by hayroob; 05-21-2009 at 02:50 PM.
(Offline)   Reply With Quote
Old 05-21-2009, 11:44 PM   #364 (permalink)
Senior Member
 
FrozenViking's Avatar
 
Join Date: May 2008
Location: Norway, its fuckin cold
Posts: 302
looks awesome =)
(Offline)   Reply With Quote
Old 05-22-2009, 12:43 AM   #365 (permalink)
Senior Member
 
yoav's Avatar
 
Join Date: Apr 2006
Posts: 1,034
Quote:
Originally Posted by hayroob View Post
This is what the countdown looks like right now. I haven't made any logic to say that if the show is live to change the label to right now or whatever. This will come next.

Also it feels cluttered so I need to tinker with layout.

And as always every time I add something it gets a little slower so I think I need to stop adding features and tune for awhile, clean up the codebase, etc.
looking good!
if you get stuck transcribing theGrundle's countdown logic i have it in 2 other languages, although i'm sure he's already got you covered... (theGrundle == godfather of katg apps)
(Offline)   Reply With Quote
Old 05-22-2009, 04:35 PM   #366 (permalink)
Senior Member
 
hayroob's Avatar
 
Join Date: Mar 2008
Location: Detroitish
Posts: 1,561
Quote:
Originally Posted by yoav View Post
looking good!
if you get stuck transcribing theGrundle's countdown logic i have it in 2 other languages, although i'm sure he's already got you covered... (theGrundle == godfather of katg apps)
I just poll the events feed and search for a live show, that is in the future. Then I make a NSDate object out of it and ask for time since now. This is fairly snappy and doesn't get tripped up by time zones.

Code:
NSDate *eventTime = [formatter dateFromString: feedTime];
			
			timeSince = [eventTime timeIntervalSinceNow];
			
			match1 = [feedTitle rangeOfString:@"Live Show" options:NSCaseInsensitiveSearch].location != NSNotFound;
			match2 = timeSince > 0;
			
			feedEntryIndex = feedEntryIndex - 1;
		}
		
		int s = 0;
		int m = 0;
		int h = 0;
		int d = 0;
		
		int temp = timeSince;
		
		if (timeSince > 60) {
			s = timeSince % 60;
			timeSince /= 60;
			
			if (timeSince > 60) {
				m = timeSince % 60;
				timeSince /= 60;
				
				if (timeSince > 24) {
					h = timeSince % 24;
					timeSince /= 24;
					d = timeSince;
				} else {
					h = timeSince;
				}
			} else {
				m = timeSince;
			}
		}
		
		timeSince = temp;
		
		days.text = [[NSString alloc] initWithFormat:@"%d",d];
		hours.text = [[NSString alloc] initWithFormat:@"%d",h];
		minutes.text = [[NSString alloc] initWithFormat:@"%d",m];
(Offline)   Reply With Quote
Old 05-22-2009, 09:11 PM   #367 (permalink)
Senior Member
 
TheGrundle's Avatar
 
Join Date: Jun 2006
Location: New Orleans
Posts: 751
Quote:
Originally Posted by hayroob View Post
I just poll the events feed and search for a live show, that is in the future. Then I make a NSDate object out of it and ask for time since now. This is fairly snappy and doesn't get tripped up by time zones.
Why all the if/then? Wouldn't something like this work? assuming timeSince = total seconds

days = timeSince \ 86400
hours = (timeSince \ 3600) - (days * 24)
minutes = (timeSince \ 60) - (days * 1440) - (hours * 60)
seconds = timeSince Mod 60


I've also done it differently in .NET

Code:
Public Function formatSecs(ByVal sSeconds As Long) As String  'Converts seconds to 0:00
        Dim tSpan As TimeSpan = New TimeSpan(0, 0, sSeconds)
        Dim sDate As DateTime = New DateTime(tSpan.Ticks)
        Return Int(tSpan.TotalHours) & sDate.ToString(":mm:ss")
End Function
Maybe you could do something similar with NSTimeDateFormatString

It just seems like a lot of code to me.

Last edited by TheGrundle; 05-22-2009 at 09:13 PM.
(Offline)   Reply With Quote
Old 05-22-2009, 09:32 PM   #368 (permalink)
Senior Member
 
yoav's Avatar
 
Join Date: Apr 2006
Posts: 1,034
Quote:
Originally Posted by hayroob View Post
I just poll the events feed and search for a live show, that is in the future. Then I make a NSDate object out of it and ask for time since now. This is fairly snappy and doesn't get tripped up by time zones.
events feed you say... as in xml/json?
(Offline)   Reply With Quote
Old 05-22-2009, 10:02 PM   #369 (permalink)
Senior Member
 
hayroob's Avatar
 
Join Date: Mar 2008
Location: Detroitish
Posts: 1,561
Quote:
Originally Posted by TheGrundle View Post
Why all the if/then? Wouldn't something like this work? assuming timeSince = total seconds

days = timeSince \ 86400
hours = (timeSince \ 3600) - (days * 24)
minutes = (timeSince \ 60) - (days * 1440) - (hours * 60)
seconds = timeSince Mod 60


I've also done it differently in .NET

Code:
Public Function formatSecs(ByVal sSeconds As Long) As String  'Converts seconds to 0:00
        Dim tSpan As TimeSpan = New TimeSpan(0, 0, sSeconds)
        Dim sDate As DateTime = New DateTime(tSpan.Ticks)
        Return Int(tSpan.TotalHours) & sDate.ToString(":mm:ss")
End Function
Maybe you could do something similar with NSTimeDateFormatString

It just seems like a lot of code to me.
You are correct. I just sort of tossed in some code I had in the twitter segment because it didn't require me to turn on my brain.

all the ifs are now
Code:
int d = timeSince / 86400;
		int h = timeSince / 3600 - d * 24;
		int m = timeSince / 60 - d * 1440 - h * 60;
		int s = timeSince % 60;
Quote:
Originally Posted by yoav View Post
events feed you say... as in xml/json?
There's an xml feed of all the events, I'll PM it to you.
(Offline)   Reply With Quote
Old 05-24-2009, 01:35 AM   #370 (permalink)
Senior Member
 
FreydNot's Avatar
 
Join Date: May 2006
Location: Seattle, WA
Posts: 362
Today I put adhocKATG1.1.com on my iPod Touch 1st gen.

It starts normally


But after 2 seconds it goes all blank


I tried rebooting the iPod but it didn't change anything.

I can press the home button to get back to the menu so it isn't crashing or anything.

It is connected to a wireless network and that is working.

Is 1.1 the current version?
(Offline)   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


All times are GMT -5. The time now is 08:52 PM.


Powered by vBulletin® Version 3.7.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
Keith and The Girl
iPhone news and app directory