From bf263da2ccf44aba71bf24a53694053ace77530a Mon Sep 17 00:00:00 2001 From: Matt Gallagher Date: Wed, 6 Apr 2011 15:46:57 +1000 Subject: [PATCH] Updated to newest version of TripleJ stream. --- Classes/AudioStreamer.h | 19 ++- Classes/AudioStreamer.m | 28 +++- Classes/MacStreamingPlayerController.h | 19 ++- Classes/MacStreamingPlayerController.m | 19 ++- Classes/iPhoneStreamingPlayerAppDelegate.h | 19 ++- Classes/iPhoneStreamingPlayerAppDelegate.m | 19 ++- Classes/iPhoneStreamingPlayerViewController.h | 19 ++- Classes/iPhoneStreamingPlayerViewController.m | 19 ++- English.lproj/MainMenu.xib | 141 ++++++++++++++++-- .../iPhoneStreamingPlayerViewController.xib | 127 +++++++++++----- main.m | 19 ++- 11 files changed, 351 insertions(+), 97 deletions(-) diff --git a/Classes/AudioStreamer.h b/Classes/AudioStreamer.h index 56273f9..a235650 100644 --- a/Classes/AudioStreamer.h +++ b/Classes/AudioStreamer.h @@ -5,11 +5,20 @@ // Created by Matt Gallagher on 27/09/08. // Copyright 2008 Matt Gallagher. All rights reserved. // -// Permission is given to use this source code file, free of charge, in any -// project, commercial or otherwise, entirely at your risk, with the condition -// that any redistribution (in part or whole) of source code must retain -// this copyright and permission notice. Attribution in compiled projects is -// appreciated but not required. +// This software is provided 'as-is', without any express or implied +// warranty. In no event will the authors be held liable for any damages +// arising from the use of this software. Permission is granted to anyone to +// use this software for any purpose, including commercial applications, and to +// alter it and redistribute it freely, subject to the following restrictions: +// +// 1. The origin of this software must not be misrepresented; you must not +// claim that you wrote the original software. If you use this software +// in a product, an acknowledgment in the product documentation would be +// appreciated but is not required. +// 2. Altered source versions must be plainly marked as such, and must not be +// misrepresented as being the original software. +// 3. This notice may not be removed or altered from any source +// distribution. // #if TARGET_OS_IPHONE diff --git a/Classes/AudioStreamer.m b/Classes/AudioStreamer.m index 5e42138..86f066b 100644 --- a/Classes/AudioStreamer.m +++ b/Classes/AudioStreamer.m @@ -5,11 +5,20 @@ // Created by Matt Gallagher on 27/09/08. // Copyright 2008 Matt Gallagher. All rights reserved. // -// Permission is given to use this source code file, free of charge, in any -// project, commercial or otherwise, entirely at your risk, with the condition -// that any redistribution (in part or whole) of source code must retain -// this copyright and permission notice. Attribution in compiled projects is -// appreciated but not required. +// This software is provided 'as-is', without any express or implied +// warranty. In no event will the authors be held liable for any damages +// arising from the use of this software. Permission is granted to anyone to +// use this software for any purpose, including commercial applications, and to +// alter it and redistribute it freely, subject to the following restrictions: +// +// 1. The origin of this software must not be misrepresented; you must not +// claim that you wrote the original software. If you use this software +// in a product, an acknowledgment in the product documentation would be +// appreciated but is not required. +// 2. Altered source versions must be plainly marked as such, and must not be +// misrepresented as being the original software. +// 3. This notice may not be removed or altered from any source +// distribution. // #import "AudioStreamer.h" @@ -566,7 +575,7 @@ - (BOOL)isIdle // + (AudioFileTypeID)hintForFileExtension:(NSString *)fileExtension { - AudioFileTypeID fileTypeHint = kAudioFileMP3Type; + AudioFileTypeID fileTypeHint = kAudioFileAAC_ADTSType; if ([fileExtension isEqual:@"mp3"]) { fileTypeHint = kAudioFileMP3Type; @@ -651,6 +660,13 @@ - (BOOL)openReadStream return NO; } + // + // Handle proxies + // + CFDictionaryRef proxySettings = CFNetworkCopySystemProxySettings(); + CFReadStreamSetProperty(stream, kCFStreamPropertyHTTPProxy, proxySettings); + CFRelease(proxySettings); + // // Handle SSL connections // diff --git a/Classes/MacStreamingPlayerController.h b/Classes/MacStreamingPlayerController.h index d952d00..55ad3c9 100644 --- a/Classes/MacStreamingPlayerController.h +++ b/Classes/MacStreamingPlayerController.h @@ -5,11 +5,20 @@ // Created by Matt Gallagher on 28/10/08. // Copyright Matt Gallagher 2008. All rights reserved. // -// Permission is given to use this source code file, free of charge, in any -// project, commercial or otherwise, entirely at your risk, with the condition -// that any redistribution (in part or whole) of source code must retain -// this copyright and permission notice. Attribution in compiled projects is -// appreciated but not required. +// This software is provided 'as-is', without any express or implied +// warranty. In no event will the authors be held liable for any damages +// arising from the use of this software. Permission is granted to anyone to +// use this software for any purpose, including commercial applications, and to +// alter it and redistribute it freely, subject to the following restrictions: +// +// 1. The origin of this software must not be misrepresented; you must not +// claim that you wrote the original software. If you use this software +// in a product, an acknowledgment in the product documentation would be +// appreciated but is not required. +// 2. Altered source versions must be plainly marked as such, and must not be +// misrepresented as being the original software. +// 3. This notice may not be removed or altered from any source +// distribution. // #import diff --git a/Classes/MacStreamingPlayerController.m b/Classes/MacStreamingPlayerController.m index 2527d67..3415150 100644 --- a/Classes/MacStreamingPlayerController.m +++ b/Classes/MacStreamingPlayerController.m @@ -5,11 +5,20 @@ // Created by Matt Gallagher on 28/10/08. // Copyright Matt Gallagher 2008. All rights reserved. // -// Permission is given to use this source code file, free of charge, in any -// project, commercial or otherwise, entirely at your risk, with the condition -// that any redistribution (in part or whole) of source code must retain -// this copyright and permission notice. Attribution in compiled projects is -// appreciated but not required. +// This software is provided 'as-is', without any express or implied +// warranty. In no event will the authors be held liable for any damages +// arising from the use of this software. Permission is granted to anyone to +// use this software for any purpose, including commercial applications, and to +// alter it and redistribute it freely, subject to the following restrictions: +// +// 1. The origin of this software must not be misrepresented; you must not +// claim that you wrote the original software. If you use this software +// in a product, an acknowledgment in the product documentation would be +// appreciated but is not required. +// 2. Altered source versions must be plainly marked as such, and must not be +// misrepresented as being the original software. +// 3. This notice may not be removed or altered from any source +// distribution. // #import "MacStreamingPlayerController.h" diff --git a/Classes/iPhoneStreamingPlayerAppDelegate.h b/Classes/iPhoneStreamingPlayerAppDelegate.h index 1db733d..985e1cc 100644 --- a/Classes/iPhoneStreamingPlayerAppDelegate.h +++ b/Classes/iPhoneStreamingPlayerAppDelegate.h @@ -5,11 +5,20 @@ // Created by Matt Gallagher on 28/10/08. // Copyright Matt Gallagher 2008. All rights reserved. // -// Permission is given to use this source code file, free of charge, in any -// project, commercial or otherwise, entirely at your risk, with the condition -// that any redistribution (in part or whole) of source code must retain -// this copyright and permission notice. Attribution in compiled projects is -// appreciated but not required. +// This software is provided 'as-is', without any express or implied +// warranty. In no event will the authors be held liable for any damages +// arising from the use of this software. Permission is granted to anyone to +// use this software for any purpose, including commercial applications, and to +// alter it and redistribute it freely, subject to the following restrictions: +// +// 1. The origin of this software must not be misrepresented; you must not +// claim that you wrote the original software. If you use this software +// in a product, an acknowledgment in the product documentation would be +// appreciated but is not required. +// 2. Altered source versions must be plainly marked as such, and must not be +// misrepresented as being the original software. +// 3. This notice may not be removed or altered from any source +// distribution. // #import diff --git a/Classes/iPhoneStreamingPlayerAppDelegate.m b/Classes/iPhoneStreamingPlayerAppDelegate.m index ae6b4c9..67ddc52 100644 --- a/Classes/iPhoneStreamingPlayerAppDelegate.m +++ b/Classes/iPhoneStreamingPlayerAppDelegate.m @@ -5,11 +5,20 @@ // Created by Matt Gallagher on 28/10/08. // Copyright Matt Gallagher 2008. All rights reserved. // -// Permission is given to use this source code file, free of charge, in any -// project, commercial or otherwise, entirely at your risk, with the condition -// that any redistribution (in part or whole) of source code must retain -// this copyright and permission notice. Attribution in compiled projects is -// appreciated but not required. +// This software is provided 'as-is', without any express or implied +// warranty. In no event will the authors be held liable for any damages +// arising from the use of this software. Permission is granted to anyone to +// use this software for any purpose, including commercial applications, and to +// alter it and redistribute it freely, subject to the following restrictions: +// +// 1. The origin of this software must not be misrepresented; you must not +// claim that you wrote the original software. If you use this software +// in a product, an acknowledgment in the product documentation would be +// appreciated but is not required. +// 2. Altered source versions must be plainly marked as such, and must not be +// misrepresented as being the original software. +// 3. This notice may not be removed or altered from any source +// distribution. // #import "iPhoneStreamingPlayerAppDelegate.h" diff --git a/Classes/iPhoneStreamingPlayerViewController.h b/Classes/iPhoneStreamingPlayerViewController.h index 6f390d7..e1d5a4f 100644 --- a/Classes/iPhoneStreamingPlayerViewController.h +++ b/Classes/iPhoneStreamingPlayerViewController.h @@ -5,11 +5,20 @@ // Created by Matt Gallagher on 28/10/08. // Copyright Matt Gallagher 2008. All rights reserved. // -// Permission is given to use this source code file, free of charge, in any -// project, commercial or otherwise, entirely at your risk, with the condition -// that any redistribution (in part or whole) of source code must retain -// this copyright and permission notice. Attribution in compiled projects is -// appreciated but not required. +// This software is provided 'as-is', without any express or implied +// warranty. In no event will the authors be held liable for any damages +// arising from the use of this software. Permission is granted to anyone to +// use this software for any purpose, including commercial applications, and to +// alter it and redistribute it freely, subject to the following restrictions: +// +// 1. The origin of this software must not be misrepresented; you must not +// claim that you wrote the original software. If you use this software +// in a product, an acknowledgment in the product documentation would be +// appreciated but is not required. +// 2. Altered source versions must be plainly marked as such, and must not be +// misrepresented as being the original software. +// 3. This notice may not be removed or altered from any source +// distribution. // #import diff --git a/Classes/iPhoneStreamingPlayerViewController.m b/Classes/iPhoneStreamingPlayerViewController.m index e9f92cb..c345ea0 100644 --- a/Classes/iPhoneStreamingPlayerViewController.m +++ b/Classes/iPhoneStreamingPlayerViewController.m @@ -5,11 +5,20 @@ // Created by Matt Gallagher on 28/10/08. // Copyright Matt Gallagher 2008. All rights reserved. // -// Permission is given to use this source code file, free of charge, in any -// project, commercial or otherwise, entirely at your risk, with the condition -// that any redistribution (in part or whole) of source code must retain -// this copyright and permission notice. Attribution in compiled projects is -// appreciated but not required. +// This software is provided 'as-is', without any express or implied +// warranty. In no event will the authors be held liable for any damages +// arising from the use of this software. Permission is granted to anyone to +// use this software for any purpose, including commercial applications, and to +// alter it and redistribute it freely, subject to the following restrictions: +// +// 1. The origin of this software must not be misrepresented; you must not +// claim that you wrote the original software. If you use this software +// in a product, an acknowledgment in the product documentation would be +// appreciated but is not required. +// 2. Altered source versions must be plainly marked as such, and must not be +// misrepresented as being the original software. +// 3. This notice may not be removed or altered from any source +// distribution. // #import "iPhoneStreamingPlayerViewController.h" diff --git a/English.lproj/MainMenu.xib b/English.lproj/MainMenu.xib index a89a835..bc03d8a 100644 --- a/English.lproj/MainMenu.xib +++ b/English.lproj/MainMenu.xib @@ -2,13 +2,13 @@ 1050 - 10C540 - 762 - 1038.25 - 458.00 + 10J869 + 851 + 1038.35 + 461.00 com.apple.InterfaceBuilder.CocoaPlugin - 762 + 851 YES @@ -19,13 +19,8 @@ com.apple.InterfaceBuilder.CocoaPlugin - YES - - YES - - - YES - + PluginDependencyRecalculationVersion + YES @@ -1167,7 +1162,7 @@ -1804468671 272630784 - http://202.6.74.107:8060/triplej.mp3 + http://shoutmedia.abc.net.au:10326 YES @@ -1871,7 +1866,9 @@ YES 0 - + + YES + @@ -3355,6 +3352,25 @@ NSSlider + + YES + + YES + buttonPressed: + sliderMoved: + + + YES + + buttonPressed: + id + + + sliderMoved: + NSSlider + + + YES @@ -3372,6 +3388,35 @@ NSSlider + + YES + + YES + button + downloadSourceField + positionLabel + progressSlider + + + YES + + button + NSButton + + + downloadSourceField + NSTextField + + + positionLabel + NSTextField + + + progressSlider + NSSlider + + + IBProjectSource Classes/MacStreamingPlayerController.h @@ -3495,6 +3540,45 @@ id + + YES + + YES + printDocument: + revertDocumentToSaved: + runPageLayout: + saveDocument: + saveDocumentAs: + saveDocumentTo: + + + YES + + printDocument: + id + + + revertDocumentToSaved: + id + + + runPageLayout: + id + + + saveDocument: + id + + + saveDocumentAs: + id + + + saveDocumentTo: + id + + + IBFrameworkSource AppKit.framework/Headers/NSDocument.h @@ -3527,6 +3611,35 @@ id + + YES + + YES + clearRecentDocuments: + newDocument: + openDocument: + saveAllDocuments: + + + YES + + clearRecentDocuments: + id + + + newDocument: + id + + + openDocument: + id + + + saveAllDocuments: + id + + + IBFrameworkSource AppKit.framework/Headers/NSDocumentController.h diff --git a/iPhone Resources/iPhoneStreamingPlayerViewController.xib b/iPhone Resources/iPhoneStreamingPlayerViewController.xib index 630d2f5..ae715de 100644 --- a/iPhone Resources/iPhoneStreamingPlayerViewController.xib +++ b/iPhone Resources/iPhoneStreamingPlayerViewController.xib @@ -2,17 +2,17 @@ 528 - 10C540 - 762 - 1038.25 - 458.00 + 10J869 + 851 + 1038.35 + 461.00 com.apple.InterfaceBuilder.IBCocoaTouchPlugin - 87 + 141 YES - + YES @@ -51,7 +51,7 @@ NO IBCocoaTouchFramework 0 - http://202.6.74.107:8060/triplej.mp3 + http://shoutmedia.abc.net.au:10326 3 3 @@ -407,6 +407,25 @@ UISlider + + YES + + YES + buttonPressed: + sliderMoved: + + + YES + + buttonPressed: + id + + + sliderMoved: + UISlider + + + YES @@ -426,6 +445,40 @@ UIView + + YES + + YES + button + downloadSourceField + positionLabel + progressSlider + volumeSlider + + + YES + + button + UIButton + + + downloadSourceField + UITextField + + + positionLabel + UILabel + + + progressSlider + UISlider + + + volumeSlider + UIView + + + IBProjectSource Classes/iPhoneStreamingPlayerViewController.h @@ -469,13 +522,6 @@ Foundation.framework/Headers/NSKeyedArchiver.h - - NSObject - - IBFrameworkSource - Foundation.framework/Headers/NSNetServices.h - - NSObject @@ -483,13 +529,6 @@ Foundation.framework/Headers/NSObject.h - - NSObject - - IBFrameworkSource - Foundation.framework/Headers/NSPort.h - - NSObject @@ -497,13 +536,6 @@ Foundation.framework/Headers/NSRunLoop.h - - NSObject - - IBFrameworkSource - Foundation.framework/Headers/NSStream.h - - NSObject @@ -525,13 +557,6 @@ Foundation.framework/Headers/NSURLConnection.h - - NSObject - - IBFrameworkSource - Foundation.framework/Headers/NSXMLParser.h - - NSObject @@ -635,6 +660,13 @@ UIKit.framework/Headers/UITextField.h + + UIView + + IBFrameworkSource + UIKit.framework/Headers/UIPrintFormatter.h + + UIView @@ -647,6 +679,13 @@ UIKit.framework/Headers/UIView.h + + UIViewController + + IBFrameworkSource + MediaPlayer.framework/Headers/MPMoviePlayerViewController.h + + UIViewController @@ -654,6 +693,20 @@ UIKit.framework/Headers/UINavigationController.h + + UIViewController + + IBFrameworkSource + UIKit.framework/Headers/UIPopoverController.h + + + + UIViewController + + IBFrameworkSource + UIKit.framework/Headers/UISplitViewController.h + + UIViewController @@ -679,7 +732,7 @@ com.apple.InterfaceBuilder.CocoaTouchPlugin.iPhoneOS - + com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3 @@ -692,6 +745,6 @@ playbutton.png {64, 64} - 87 + 141 diff --git a/main.m b/main.m index d30b4ef..417a8dd 100644 --- a/main.m +++ b/main.m @@ -5,11 +5,20 @@ // Created by Matt Gallagher on 28/10/08. // Copyright Matt Gallagher 2008. All rights reserved. // -// Permission is given to use this source code file, free of charge, in any -// project, commercial or otherwise, entirely at your risk, with the condition -// that any redistribution (in part or whole) of source code must retain -// this copyright and permission notice. Attribution in compiled projects is -// appreciated but not required. +// This software is provided 'as-is', without any express or implied +// warranty. In no event will the authors be held liable for any damages +// arising from the use of this software. Permission is granted to anyone to +// use this software for any purpose, including commercial applications, and to +// alter it and redistribute it freely, subject to the following restrictions: +// +// 1. The origin of this software must not be misrepresented; you must not +// claim that you wrote the original software. If you use this software +// in a product, an acknowledgment in the product documentation would be +// appreciated but is not required. +// 2. Altered source versions must be plainly marked as such, and must not be +// misrepresented as being the original software. +// 3. This notice may not be removed or altered from any source +// distribution. // #if TARGET_OS_IPHONE