Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Added a bunch of stuff

  • Loading branch information...
commit fbfcd04af90fcea5b95abb8a3ae6cfd9db43d036 1 parent b35f2e8
Steve authored
View
104 URL Shrink.xcodeproj/project.pbxproj
@@ -18,6 +18,12 @@
AA796C3C0F8130EE00D9C477 /* USShrinkController.m in Sources */ = {isa = PBXBuildFile; fileRef = AA796C3B0F8130EE00D9C477 /* USShrinkController.m */; };
AA796C870F813BB100D9C477 /* USIsGdShrinker.m in Sources */ = {isa = PBXBuildFile; fileRef = AA796C860F813BB100D9C477 /* USIsGdShrinker.m */; };
AA796D3C0F8144E200D9C477 /* USLoopbackShrinker.m in Sources */ = {isa = PBXBuildFile; fileRef = AA796D3B0F8144E200D9C477 /* USLoopbackShrinker.m */; };
+ AA796F990F81550D00D9C477 /* tool_main.m in Sources */ = {isa = PBXBuildFile; fileRef = AA796F980F81550D00D9C477 /* tool_main.m */; };
+ AA796F9A0F81554200D9C477 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 29B97325FDCFA39411CA2CEA /* Foundation.framework */; };
+ AA796FA20F815B7700D9C477 /* USIsGdShrinker.m in Sources */ = {isa = PBXBuildFile; fileRef = AA796C860F813BB100D9C477 /* USIsGdShrinker.m */; };
+ AA796FA30F815B7700D9C477 /* USLoopbackShrinker.m in Sources */ = {isa = PBXBuildFile; fileRef = AA796D3B0F8144E200D9C477 /* USLoopbackShrinker.m */; };
+ AA796FA40F815B7700D9C477 /* USShrinkController.m in Sources */ = {isa = PBXBuildFile; fileRef = AA796C3B0F8130EE00D9C477 /* USShrinkController.m */; };
+ AA796FA50F815B7700D9C477 /* USURLShrinker.m in Sources */ = {isa = PBXBuildFile; fileRef = AA796A880F811D1800D9C477 /* USURLShrinker.m */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
@@ -45,6 +51,8 @@
AA796C860F813BB100D9C477 /* USIsGdShrinker.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = USIsGdShrinker.m; sourceTree = "<group>"; };
AA796D3A0F8144E200D9C477 /* USLoopbackShrinker.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = USLoopbackShrinker.h; sourceTree = "<group>"; };
AA796D3B0F8144E200D9C477 /* USLoopbackShrinker.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = USLoopbackShrinker.m; sourceTree = "<group>"; };
+ AA796D7E0F81546300D9C477 /* shrink */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; name = shrink; path = build/Debug/shrink; sourceTree = "<group>"; };
+ AA796F980F81550D00D9C477 /* tool_main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = tool_main.m; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
@@ -57,6 +65,14 @@
);
runOnlyForDeploymentPostprocessing = 0;
};
+ AA796D7C0F81546300D9C477 /* Frameworks */ = {
+ isa = PBXFrameworksBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ AA796F9A0F81554200D9C477 /* Foundation.framework in Frameworks */,
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
@@ -83,6 +99,7 @@
1058C7A0FEA54F0111CA2CBB /* Linked Frameworks */ = {
isa = PBXGroup;
children = (
+ AA796A8D0F811D6000D9C477 /* Carbon.framework */,
1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */,
);
name = "Linked Frameworks";
@@ -102,6 +119,7 @@
isa = PBXGroup;
children = (
8D1107320486CEB800E47090 /* URL Shrink.app */,
+ AA796D7E0F81546300D9C477 /* shrink */,
);
name = Products;
sourceTree = "<group>";
@@ -114,7 +132,6 @@
29B97317FDCFA39411CA2CEA /* Resources */,
29B97323FDCFA39411CA2CEA /* Frameworks */,
19C28FACFE9D520D11CA2CBB /* Products */,
- AA796A8D0F811D6000D9C477 /* Carbon.framework */,
);
name = "URL Shrink";
sourceTree = "<group>";
@@ -124,6 +141,7 @@
children = (
32CA4F630368D1EE00C91783 /* URL Shrink_Prefix.pch */,
29B97316FDCFA39411CA2CEA /* main.m */,
+ AA796F980F81550D00D9C477 /* tool_main.m */,
);
name = "Other Sources";
sourceTree = "<group>";
@@ -168,6 +186,22 @@
productReference = 8D1107320486CEB800E47090 /* URL Shrink.app */;
productType = "com.apple.product-type.application";
};
+ AA796D7D0F81546300D9C477 /* shrink */ = {
+ isa = PBXNativeTarget;
+ buildConfigurationList = AA796E4A0F81547700D9C477 /* Build configuration list for PBXNativeTarget "shrink" */;
+ buildPhases = (
+ AA796D7B0F81546300D9C477 /* Sources */,
+ AA796D7C0F81546300D9C477 /* Frameworks */,
+ );
+ buildRules = (
+ );
+ dependencies = (
+ );
+ name = shrink;
+ productName = shrink;
+ productReference = AA796D7E0F81546300D9C477 /* shrink */;
+ productType = "com.apple.product-type.tool";
+ };
/* End PBXNativeTarget section */
/* Begin PBXProject section */
@@ -181,6 +215,7 @@
projectRoot = "";
targets = (
8D1107260486CEB800E47090 /* URL Shrink */,
+ AA796D7D0F81546300D9C477 /* shrink */,
);
};
/* End PBXProject section */
@@ -212,6 +247,18 @@
);
runOnlyForDeploymentPostprocessing = 0;
};
+ AA796D7B0F81546300D9C477 /* Sources */ = {
+ isa = PBXSourcesBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ AA796FA20F815B7700D9C477 /* USIsGdShrinker.m in Sources */,
+ AA796FA30F815B7700D9C477 /* USLoopbackShrinker.m in Sources */,
+ AA796FA40F815B7700D9C477 /* USShrinkController.m in Sources */,
+ AA796FA50F815B7700D9C477 /* USURLShrinker.m in Sources */,
+ AA796F990F81550D00D9C477 /* tool_main.m in Sources */,
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
/* End PBXSourcesBuildPhase section */
/* Begin PBXVariantGroup section */
@@ -234,6 +281,52 @@
/* End PBXVariantGroup section */
/* Begin XCBuildConfiguration section */
+ AA796D800F81546400D9C477 /* Debug */ = {
+ isa = XCBuildConfiguration;
+ buildSettings = {
+ ALWAYS_SEARCH_USER_PATHS = NO;
+ COPY_PHASE_STRIP = NO;
+ GCC_DYNAMIC_NO_PIC = NO;
+ GCC_ENABLE_FIX_AND_CONTINUE = YES;
+ GCC_MODEL_TUNING = G5;
+ GCC_OPTIMIZATION_LEVEL = 0;
+ GCC_PRECOMPILE_PREFIX_HEADER = YES;
+ GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h";
+ INSTALL_PATH = /usr/local/bin;
+ OTHER_LDFLAGS = (
+ "-framework",
+ Foundation,
+ "-framework",
+ AppKit,
+ );
+ PREBINDING = NO;
+ PRODUCT_NAME = shrink;
+ };
+ name = Debug;
+ };
+ AA796D810F81546400D9C477 /* Release */ = {
+ isa = XCBuildConfiguration;
+ buildSettings = {
+ ALWAYS_SEARCH_USER_PATHS = NO;
+ COPY_PHASE_STRIP = YES;
+ DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
+ GCC_ENABLE_FIX_AND_CONTINUE = NO;
+ GCC_MODEL_TUNING = G5;
+ GCC_PRECOMPILE_PREFIX_HEADER = YES;
+ GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h";
+ INSTALL_PATH = /usr/local/bin;
+ OTHER_LDFLAGS = (
+ "-framework",
+ Foundation,
+ "-framework",
+ AppKit,
+ );
+ PREBINDING = NO;
+ PRODUCT_NAME = shrink;
+ ZERO_LINK = NO;
+ };
+ name = Release;
+ };
C01FCF4B08A954540054247B /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
@@ -294,6 +387,15 @@
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
+ AA796E4A0F81547700D9C477 /* Build configuration list for PBXNativeTarget "shrink" */ = {
+ isa = XCConfigurationList;
+ buildConfigurations = (
+ AA796D800F81546400D9C477 /* Debug */,
+ AA796D810F81546400D9C477 /* Release */,
+ );
+ defaultConfigurationIsVisible = 0;
+ defaultConfigurationName = Release;
+ };
C01FCF4A08A954540054247B /* Build configuration list for PBXNativeTarget "URL Shrink" */ = {
isa = XCConfigurationList;
buildConfigurations = (
View
3,756 URL Shrink.xcodeproj/steve.pbxuser
901 additions, 2,855 deletions not shown
View
72 URL Shrink.xcodeproj/steve.perspectivev3
@@ -3,7 +3,7 @@
<plist version="1.0">
<dict>
<key>ActivePerspectiveName</key>
- <string>Debug</string>
+ <string>Project</string>
<key>AllowedModules</key>
<array>
<dict>
@@ -278,16 +278,24 @@
<string>080E96DDFE201D6D7F000001</string>
<string>29B97315FDCFA39411CA2CEA</string>
<string>29B97317FDCFA39411CA2CEA</string>
+ <string>29B97323FDCFA39411CA2CEA</string>
+ <string>1058C7A0FEA54F0111CA2CBB</string>
+ <string>1058C7A2FEA54F0111CA2CBB</string>
<string>1C37FBAC04509CD000000102</string>
- <string>AA796AA20F811E5B00D9C477</string>
- <string>AA796D070F8141BF00D9C477</string>
+ <string>AA796E400F81547700D9C477</string>
+ <string>AA796E410F81547700D9C477</string>
+ <string>AA796E420F81547700D9C477</string>
+ <string>AA796E430F81547700D9C477</string>
+ <string>AA796E440F81547700D9C477</string>
+ <string>AA796E450F81547700D9C477</string>
</array>
<key>PBXSmartGroupTreeModuleOutlineStateSelectionKey</key>
<array>
<array>
- <integer>19</integer>
- <integer>18</integer>
- <integer>0</integer>
+ <integer>52</integer>
+ <integer>47</integer>
+ <integer>46</integer>
+ <integer>32</integer>
</array>
</array>
<key>PBXSmartGroupTreeModuleOutlineStateVisibleRectKey</key>
@@ -307,6 +315,8 @@
<string>MainColumn</string>
<real>185</real>
</array>
+ <key>RubberWindowFrame</key>
+ <string>0 151 1632 1027 0 0 1920 1178 </string>
</dict>
<key>Module</key>
<string>PBXSmartGroupTreeModule</string>
@@ -317,12 +327,14 @@
<key>Dock</key>
<array>
<dict>
+ <key>BecomeActive</key>
+ <true/>
<key>ContentConfiguration</key>
<dict>
<key>PBXProjectModuleGUID</key>
<string>AA7CF1A30D7E053000D79611</string>
<key>PBXProjectModuleLabel</key>
- <string>Info.plist</string>
+ <string>tool_main.m</string>
<key>PBXSplitModuleInNavigatorKey</key>
<dict>
<key>Split0</key>
@@ -330,11 +342,11 @@
<key>PBXProjectModuleGUID</key>
<string>AA7CF1A40D7E053000D79611</string>
<key>PBXProjectModuleLabel</key>
- <string>Info.plist</string>
+ <string>tool_main.m</string>
<key>_historyCapacity</key>
<integer>0</integer>
<key>bookmark</key>
- <string>AA796D580F81455200D9C477</string>
+ <string>AA796FAD0F815D3200D9C477</string>
<key>history</key>
<array>
<string>AA796C150F81275900D9C477</string>
@@ -345,17 +357,19 @@
<string>AA796C450F81360300D9C477</string>
<string>AA796C650F81394200D9C477</string>
<string>AA796C660F81394200D9C477</string>
- <string>AA796CC80F813EBA00D9C477</string>
<string>AA796CDD0F81410C00D9C477</string>
- <string>AA796CF20F81414F00D9C477</string>
<string>AA796D150F8142B300D9C477</string>
- <string>AA796D2D0F81443000D9C477</string>
- <string>AA796D2E0F81443000D9C477</string>
- <string>AA796D3F0F81452100D9C477</string>
<string>AA796D400F81452100D9C477</string>
- <string>AA796D4C0F81454000D9C477</string>
- <string>AA796D540F81455100D9C477</string>
- <string>AA796D550F81455100D9C477</string>
+ <string>AA796D5D0F8145B000D9C477</string>
+ <string>AA796D5E0F8145B000D9C477</string>
+ <string>AA796D600F8145B000D9C477</string>
+ <string>AA796D6B0F8151C100D9C477</string>
+ <string>AA796E460F81547700D9C477</string>
+ <string>AA796F9B0F81554C00D9C477</string>
+ <string>AA796F9C0F81554C00D9C477</string>
+ <string>AA796FA60F815B7C00D9C477</string>
+ <string>AA796FA70F815B7C00D9C477</string>
+ <string>AA796FA80F815B7C00D9C477</string>
</array>
<key>prevStack</key>
<array>
@@ -459,6 +473,18 @@
<string>AA796D430F81452100D9C477</string>
<string>AA796D490F81453700D9C477</string>
<string>AA796D560F81455100D9C477</string>
+ <string>AA796D620F8145B000D9C477</string>
+ <string>AA796D630F8145B000D9C477</string>
+ <string>AA796D640F8145B000D9C477</string>
+ <string>AA796D650F8145B000D9C477</string>
+ <string>AA796D6D0F8151C100D9C477</string>
+ <string>AA796E480F81547700D9C477</string>
+ <string>AA796F9E0F81554C00D9C477</string>
+ <string>AA796F9F0F81554C00D9C477</string>
+ <string>AA796FA00F81554C00D9C477</string>
+ <string>AA796FA90F815B7C00D9C477</string>
+ <string>AA796FAA0F815B7C00D9C477</string>
+ <string>AA796FAB0F815B7C00D9C477</string>
</array>
</dict>
<key>SplitCount</key>
@@ -473,6 +499,8 @@
<dict>
<key>Frame</key>
<string>{{0, 0}, {1425, 617}}</string>
+ <key>RubberWindowFrame</key>
+ <string>0 151 1632 1027 0 0 1920 1178 </string>
</dict>
<key>Module</key>
<string>PBXNavigatorGroup</string>
@@ -496,6 +524,8 @@
<dict>
<key>Frame</key>
<string>{{10, 27}, {1425, 337}}</string>
+ <key>RubberWindowFrame</key>
+ <string>0 151 1632 1027 0 0 1920 1178 </string>
</dict>
<key>Module</key>
<string>XCDetailModule</string>
@@ -619,8 +649,6 @@
<key>Layout</key>
<array>
<dict>
- <key>BecomeActive</key>
- <true/>
<key>ContentConfiguration</key>
<dict>
<key>PBXProjectModuleGUID</key>
@@ -632,8 +660,6 @@
<dict>
<key>Frame</key>
<string>{{0, 0}, {1632, 264}}</string>
- <key>RubberWindowFrame</key>
- <string>0 151 1632 1027 0 0 1920 1178 </string>
</dict>
<key>Module</key>
<string>PBXDebugCLIModule</string>
@@ -708,11 +734,7 @@
</array>
<key>Frame</key>
<string>{{0, 358}, {816, 359}}</string>
- <key>RubberWindowFrame</key>
- <string>0 151 1632 1027 0 0 1920 1178 </string>
</dict>
- <key>RubberWindowFrame</key>
- <string>0 151 1632 1027 0 0 1920 1178 </string>
</dict>
<key>Module</key>
<string>PBXDebugSessionModule</string>
View
2  USAppController.h
@@ -3,7 +3,7 @@
// URL Shrink
//
// Created by Steve on 3/30/09.
-// Copyright 2009 Ambrosia Software. All rights reserved.
+// Copyright 2009 Steve Streza. All rights reserved.
//
#import "USIncludes.h"
View
13 USAppController.m
@@ -3,7 +3,7 @@
// URL Shrink
//
// Created by Steve on 3/30/09.
-// Copyright 2009 Ambrosia Software. All rights reserved.
+// Copyright 2009 Steve Streza. All rights reserved.
//
#import "USAppController.h"
@@ -50,6 +50,17 @@ -(void)shrinkURL:(EventRef)ev{
urlString = [pboard stringForType:NSStringPboardType];
}
+ //sanitize the URL string before handing it off to NSURL
+ //from Dan Wood, http://stackoverflow.com/questions/192944/whats-the-best-way-to-validate-a-user-entered-url-in-a-cocoa-application
+
+ if(urlString){
+ urlString = NSMakeCollectable(CFURLCreateStringByAddingPercentEscapes(NULL,
+ (CFStringRef)urlString,
+ (CFStringRef)@"%+#", // Characters to leave unescaped
+ NULL,
+ kCFStringEncodingUTF8));
+ }
+
if(urlString && !url){
url = [NSURL URLWithString:urlString];
}
View
2  USIsGdShrinker.h
@@ -3,7 +3,7 @@
// URL Shrink
//
// Created by Steve on 3/30/09.
-// Copyright 2009 Ambrosia Software. All rights reserved.
+// Copyright 2009 Steve Streza. All rights reserved.
//
#import <Cocoa/Cocoa.h>
View
2  USIsGdShrinker.m
@@ -3,7 +3,7 @@
// URL Shrink
//
// Created by Steve on 3/30/09.
-// Copyright 2009 Ambrosia Software. All rights reserved.
+// Copyright 2009 Steve Streza. All rights reserved.
//
#import "USIsGdShrinker.h"
View
2  USLoopbackShrinker.h
@@ -3,7 +3,7 @@
// URL Shrink
//
// Created by Steve on 3/30/09.
-// Copyright 2009 Ambrosia Software. All rights reserved.
+// Copyright 2009 Steve Streza. All rights reserved.
//
#import <Cocoa/Cocoa.h>
View
2  USLoopbackShrinker.m
@@ -3,7 +3,7 @@
// URL Shrink
//
// Created by Steve on 3/30/09.
-// Copyright 2009 Ambrosia Software. All rights reserved.
+// Copyright 2009 Steve Streza. All rights reserved.
//
#import "USLoopbackShrinker.h"
View
2  USShrinkController.h
@@ -3,7 +3,7 @@
// URL Shrink
//
// Created by Steve on 3/30/09.
-// Copyright 2009 Ambrosia Software. All rights reserved.
+// Copyright 2009 Steve Streza. All rights reserved.
//
#import "USIncludes.h"
View
3  USShrinkController.m
@@ -3,7 +3,7 @@
// URL Shrink
//
// Created by Steve on 3/30/09.
-// Copyright 2009 Ambrosia Software. All rights reserved.
+// Copyright 2009 Steve Streza. All rights reserved.
//
#import "USShrinkController.h"
@@ -35,6 +35,7 @@ -(USURLShrinker *)shrinker{
//get the user's preferred class
NSString *defaultsValue = [[NSUserDefaults standardUserDefaults] stringForKey:kUSShrinkChoiceDefaultsKey];
if(defaultsValue && [shrinkers objectForKey:defaultsValue]){
+ NSLog(@"Found user default: %@",defaultsValue);
shrinkerClass = [shrinkers objectForKey:defaultsValue];
}
View
2  USURLShrinker.h
@@ -3,7 +3,7 @@
// URL Shrink
//
// Created by Steve on 3/30/09.
-// Copyright 2009 Ambrosia Software. All rights reserved.
+// Copyright 2009 Steve Streza. All rights reserved.
//
#import "USIncludes.h"
View
2  USURLShrinker.m
@@ -3,7 +3,7 @@
// URL Shrink
//
// Created by Steve on 3/30/09.
-// Copyright 2009 Ambrosia Software. All rights reserved.
+// Copyright 2009 Steve Streza. All rights reserved.
//
#import "USURLShrinker.h"
View
2  main.m
@@ -3,7 +3,7 @@
// URL Shrink
//
// Created by Steve on 3/30/09.
-// Copyright Ambrosia Software 2009. All rights reserved.
+// Copyright 2009 Steve STreza. All rights reserved.
//
#import <Cocoa/Cocoa.h>
View
15 tool_main.m
@@ -0,0 +1,15 @@
+/*
+ * tool_main.m
+ * URL Shrink
+ *
+ * Created by Steve on 3/30/09.
+ * Copyright 2009 Steve Streza. All rights reserved.
+ *
+ */
+
+#import <Cocoa/Cocoa.h>
+
+int main(int argc, char *argv[]){
+ return 0;
+
+}
Please sign in to comment.
Something went wrong with that request. Please try again.