Permalink
Browse files

1.7

  • Loading branch information...
1 parent 591f918 commit 06b875cda58d7877e85f2326d179808b32a124e5 Matt Curtis committed Nov 30, 2015
Showing with 316 additions and 49 deletions.
  1. BIN Constraint Demos.sketch
  2. +0 −1 Fluid.sketchplugin/Contents/Resources/MCSketchBundleLoaderFramework.framework/Headers
  3. +17 −0 ...ontents/Resources/MCSketchBundleLoaderFramework.framework/Headers/MCSketchBundleLoaderFramework.h
  4. BIN ...chplugin/Contents/Resources/MCSketchBundleLoaderFramework.framework/MCSketchBundleLoaderFramework
  5. BIN ...chplugin/Contents/Resources/MCSketchBundleLoaderFramework.framework/MCSketchBundleLoaderFramework
  6. +0 −1 Fluid.sketchplugin/Contents/Resources/MCSketchBundleLoaderFramework.framework/Modules
  7. +6 −0 ....sketchplugin/Contents/Resources/MCSketchBundleLoaderFramework.framework/Modules/module.modulemap
  8. +0 −1 Fluid.sketchplugin/Contents/Resources/MCSketchBundleLoaderFramework.framework/Resources
  9. +46 −0 Fluid.sketchplugin/Contents/Resources/MCSketchBundleLoaderFramework.framework/Resources/Info.plist
  10. +0 −1 Fluid.sketchplugin/Contents/Resources/MCSketchBundleLoaderFramework.framework/Versions/Current
  11. +17 −0 .../MCSketchBundleLoaderFramework.framework/Versions/Current/Headers/MCSketchBundleLoaderFramework.h
  12. BIN .../Resources/MCSketchBundleLoaderFramework.framework/Versions/Current/MCSketchBundleLoaderFramework
  13. +6 −0 ...tents/Resources/MCSketchBundleLoaderFramework.framework/Versions/Current/Modules/module.modulemap
  14. +46 −0 .../Contents/Resources/MCSketchBundleLoaderFramework.framework/Versions/Current/Resources/Info.plist
  15. +3 −3 Fluid.sketchplugin/Contents/Resources/MCSketchConstraints.bundle/Contents/Info.plist
  16. BIN Fluid.sketchplugin/Contents/Resources/MCSketchConstraints.bundle/Contents/MacOS/MCSketchConstraints
  17. BIN Fluid.sketchplugin/Contents/Resources/MCSketchConstraints.bundle/Contents/Resources/Assets.car
  18. BIN ...nts/Resources/MCSketchConstraints.bundle/Contents/Resources/MCArtboardPreviewWindowController.nib
  19. BIN .../Contents/Resources/MCSketchConstraints.bundle/Contents/Resources/MCLayerConstraintsInspector.nib
  20. BIN Fluid.sketchplugin/Contents/Resources/MCSketchConstraints.bundle/Contents/Resources/MCSActionBar.nib
  21. BIN ...etchplugin/Contents/Resources/MCSketchConstraints.bundle/Contents/Resources/MCSSettingsWindow.nib
  22. BIN ...plugin/Contents/Resources/MCSketchConstraints.bundle/Contents/Resources/MCSizePresetsListView.nib
  23. BIN ...chConstraints.bundle/Contents/Resources/MCSketchPluginFramework.framework/MCSketchPluginFramework
  24. BIN ...chConstraints.bundle/Contents/Resources/MCSketchPluginFramework.framework/MCSketchPluginFramework
  25. +0 −1 ...sources/MCSketchConstraints.bundle/Contents/Resources/MCSketchPluginFramework.framework/Resources
  26. +46 −0 ...ketchConstraints.bundle/Contents/Resources/MCSketchPluginFramework.framework/Resources/Info.plist
  27. BIN ...le/Contents/Resources/MCSketchPluginFramework.framework/Resources/MCSPluginUpdatePromptWindow.nib
  28. BIN ...ts.bundle/Contents/Resources/MCSketchPluginFramework.framework/Versions/A/MCSketchPluginFramework
  29. +3 −3 ...aints.bundle/Contents/Resources/MCSketchPluginFramework.framework/Versions/A/Resources/Info.plist
  30. BIN .../Resources/MCSketchPluginFramework.framework/Versions/A/Resources/MCSPluginUpdatePromptWindow.nib
  31. +0 −1 .../MCSketchConstraints.bundle/Contents/Resources/MCSketchPluginFramework.framework/Versions/Current
  32. BIN ...dle/Contents/Resources/MCSketchPluginFramework.framework/Versions/Current/MCSketchPluginFramework
  33. +46 −0 ...bundle/Contents/Resources/MCSketchPluginFramework.framework/Versions/Current/Resources/Info.plist
  34. BIN ...rces/MCSketchPluginFramework.framework/Versions/Current/Resources/MCSPluginUpdatePromptWindow.nib
  35. +1 −0 Fluid.sketchplugin/Contents/Sketch/SketchLibrary.js
  36. +17 −5 Fluid.sketchplugin/Contents/Sketch/commands.js
  37. +8 −7 Fluid.sketchplugin/Contents/Sketch/main.js
  38. +18 −2 Fluid.sketchplugin/Contents/Sketch/manifest.json
  39. +36 −23 README.md
View
Binary file not shown.
@@ -0,0 +1,17 @@
+//
+// MCSketchBundleLoaderFramework.h
+// MCSketchBundleLoaderFramework
+//
+// Created by Matt Curtis on 7/22/15.
+// Copyright (c) 2015 Matt. All rights reserved.
+//
+
+#import <Cocoa/Cocoa.h>
+
+//! Project version number for MCSketchBundleLoaderFramework.
+FOUNDATION_EXPORT double MCSketchBundleLoaderFrameworkVersionNumber;
+
+//! Project version string for MCSketchBundleLoaderFramework.
+FOUNDATION_EXPORT const unsigned char MCSketchBundleLoaderFrameworkVersionString[];
+
+#import "MCSketchBundleLoader.h"
@@ -0,0 +1,6 @@
+framework module MCSketchBundleLoaderFramework {
+ umbrella header "MCSketchBundleLoaderFramework.h"
+
+ export *
+ module * { export * }
+}
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+ <key>BuildMachineOSBuild</key>
+ <string>14F27</string>
+ <key>CFBundleDevelopmentRegion</key>
+ <string>en</string>
+ <key>CFBundleExecutable</key>
+ <string>MCSketchBundleLoaderFramework</string>
+ <key>CFBundleIdentifier</key>
+ <string>matt-curtis.MCSketchBundleLoaderFramework</string>
+ <key>CFBundleInfoDictionaryVersion</key>
+ <string>6.0</string>
+ <key>CFBundleName</key>
+ <string>MCSketchBundleLoaderFramework</string>
+ <key>CFBundlePackageType</key>
+ <string>FMWK</string>
+ <key>CFBundleShortVersionString</key>
+ <string>1.0</string>
+ <key>CFBundleSignature</key>
+ <string>????</string>
+ <key>CFBundleSupportedPlatforms</key>
+ <array>
+ <string>MacOSX</string>
+ </array>
+ <key>CFBundleVersion</key>
+ <string>1</string>
+ <key>DTCompiler</key>
+ <string>com.apple.compilers.llvm.clang.1_0</string>
+ <key>DTPlatformBuild</key>
+ <string>7A1001</string>
+ <key>DTPlatformVersion</key>
+ <string>GM</string>
+ <key>DTSDKBuild</key>
+ <string>15A278</string>
+ <key>DTSDKName</key>
+ <string>macosx10.11</string>
+ <key>DTXcode</key>
+ <string>0701</string>
+ <key>DTXcodeBuild</key>
+ <string>7A1001</string>
+ <key>NSHumanReadableCopyright</key>
+ <string>Copyright © 2015 Matt. All rights reserved.</string>
+</dict>
+</plist>
@@ -0,0 +1,17 @@
+//
+// MCSketchBundleLoaderFramework.h
+// MCSketchBundleLoaderFramework
+//
+// Created by Matt Curtis on 7/22/15.
+// Copyright (c) 2015 Matt. All rights reserved.
+//
+
+#import <Cocoa/Cocoa.h>
+
+//! Project version number for MCSketchBundleLoaderFramework.
+FOUNDATION_EXPORT double MCSketchBundleLoaderFrameworkVersionNumber;
+
+//! Project version string for MCSketchBundleLoaderFramework.
+FOUNDATION_EXPORT const unsigned char MCSketchBundleLoaderFrameworkVersionString[];
+
+#import "MCSketchBundleLoader.h"
@@ -0,0 +1,6 @@
+framework module MCSketchBundleLoaderFramework {
+ umbrella header "MCSketchBundleLoaderFramework.h"
+
+ export *
+ module * { export * }
+}
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+ <key>BuildMachineOSBuild</key>
+ <string>14F27</string>
+ <key>CFBundleDevelopmentRegion</key>
+ <string>en</string>
+ <key>CFBundleExecutable</key>
+ <string>MCSketchBundleLoaderFramework</string>
+ <key>CFBundleIdentifier</key>
+ <string>matt-curtis.MCSketchBundleLoaderFramework</string>
+ <key>CFBundleInfoDictionaryVersion</key>
+ <string>6.0</string>
+ <key>CFBundleName</key>
+ <string>MCSketchBundleLoaderFramework</string>
+ <key>CFBundlePackageType</key>
+ <string>FMWK</string>
+ <key>CFBundleShortVersionString</key>
+ <string>1.0</string>
+ <key>CFBundleSignature</key>
+ <string>????</string>
+ <key>CFBundleSupportedPlatforms</key>
+ <array>
+ <string>MacOSX</string>
+ </array>
+ <key>CFBundleVersion</key>
+ <string>1</string>
+ <key>DTCompiler</key>
+ <string>com.apple.compilers.llvm.clang.1_0</string>
+ <key>DTPlatformBuild</key>
+ <string>7A1001</string>
+ <key>DTPlatformVersion</key>
+ <string>GM</string>
+ <key>DTSDKBuild</key>
+ <string>15A278</string>
+ <key>DTSDKName</key>
+ <string>macosx10.11</string>
+ <key>DTXcode</key>
+ <string>0701</string>
+ <key>DTXcodeBuild</key>
+ <string>7A1001</string>
+ <key>NSHumanReadableCopyright</key>
+ <string>Copyright © 2015 Matt. All rights reserved.</string>
+</dict>
+</plist>
@@ -29,17 +29,17 @@
<key>DTCompiler</key>
<string>com.apple.compilers.llvm.clang.1_0</string>
<key>DTPlatformBuild</key>
- <string>7B91b</string>
+ <string>7B1005</string>
<key>DTPlatformVersion</key>
<string>GM</string>
<key>DTSDKBuild</key>
<string>15A278</string>
<key>DTSDKName</key>
<string>macosx10.11</string>
<key>DTXcode</key>
- <string>0710</string>
+ <string>0711</string>
<key>DTXcodeBuild</key>
- <string>7B91b</string>
+ <string>7B1005</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright © 2015 Matt. All rights reserved.</string>
</dict>
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+ <key>BuildMachineOSBuild</key>
+ <string>14F27</string>
+ <key>CFBundleDevelopmentRegion</key>
+ <string>en</string>
+ <key>CFBundleExecutable</key>
+ <string>MCSketchPluginFramework</string>
+ <key>CFBundleIdentifier</key>
+ <string>matt-curtis.MCSketchPluginFramework</string>
+ <key>CFBundleInfoDictionaryVersion</key>
+ <string>6.0</string>
+ <key>CFBundleName</key>
+ <string>MCSketchPluginFramework</string>
+ <key>CFBundlePackageType</key>
+ <string>FMWK</string>
+ <key>CFBundleShortVersionString</key>
+ <string>1.0</string>
+ <key>CFBundleSignature</key>
+ <string>????</string>
+ <key>CFBundleSupportedPlatforms</key>
+ <array>
+ <string>MacOSX</string>
+ </array>
+ <key>CFBundleVersion</key>
+ <string>1</string>
+ <key>DTCompiler</key>
+ <string>com.apple.compilers.llvm.clang.1_0</string>
+ <key>DTPlatformBuild</key>
+ <string>7B1005</string>
+ <key>DTPlatformVersion</key>
+ <string>GM</string>
+ <key>DTSDKBuild</key>
+ <string>15A278</string>
+ <key>DTSDKName</key>
+ <string>macosx10.11</string>
+ <key>DTXcode</key>
+ <string>0711</string>
+ <key>DTXcodeBuild</key>
+ <string>7B1005</string>
+ <key>NSHumanReadableCopyright</key>
+ <string>Copyright © 2015 Matt. All rights reserved.</string>
+</dict>
+</plist>
@@ -29,17 +29,17 @@
<key>DTCompiler</key>
<string>com.apple.compilers.llvm.clang.1_0</string>
<key>DTPlatformBuild</key>
- <string>7B91b</string>
+ <string>7B1005</string>
<key>DTPlatformVersion</key>
<string>GM</string>
<key>DTSDKBuild</key>
<string>15A278</string>
<key>DTSDKName</key>
<string>macosx10.11</string>
<key>DTXcode</key>
- <string>0710</string>
+ <string>0711</string>
<key>DTXcodeBuild</key>
- <string>7B91b</string>
+ <string>7B1005</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright © 2015 Matt. All rights reserved.</string>
</dict>
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+ <key>BuildMachineOSBuild</key>
+ <string>14F27</string>
+ <key>CFBundleDevelopmentRegion</key>
+ <string>en</string>
+ <key>CFBundleExecutable</key>
+ <string>MCSketchPluginFramework</string>
+ <key>CFBundleIdentifier</key>
+ <string>matt-curtis.MCSketchPluginFramework</string>
+ <key>CFBundleInfoDictionaryVersion</key>
+ <string>6.0</string>
+ <key>CFBundleName</key>
+ <string>MCSketchPluginFramework</string>
+ <key>CFBundlePackageType</key>
+ <string>FMWK</string>
+ <key>CFBundleShortVersionString</key>
+ <string>1.0</string>
+ <key>CFBundleSignature</key>
+ <string>????</string>
+ <key>CFBundleSupportedPlatforms</key>
+ <array>
+ <string>MacOSX</string>
+ </array>
+ <key>CFBundleVersion</key>
+ <string>1</string>
+ <key>DTCompiler</key>
+ <string>com.apple.compilers.llvm.clang.1_0</string>
+ <key>DTPlatformBuild</key>
+ <string>7B1005</string>
+ <key>DTPlatformVersion</key>
+ <string>GM</string>
+ <key>DTSDKBuild</key>
+ <string>15A278</string>
+ <key>DTSDKName</key>
+ <string>macosx10.11</string>
+ <key>DTXcode</key>
+ <string>0711</string>
+ <key>DTXcodeBuild</key>
+ <string>7B1005</string>
+ <key>NSHumanReadableCopyright</key>
+ <string>Copyright © 2015 Matt. All rights reserved.</string>
+</dict>
+</plist>
@@ -43,6 +43,7 @@
//
// CONTEXT
+ // -------
//
var ctx;
@@ -5,25 +5,37 @@
// --------
$.commands.createCommand("toggleToolbarVisiblity", function(ctx){
- var pluginController = MCSConstraintsPluginController.pluginController_(ctx.command);
+ var pluginController = [MCFluidPluginController pluginController:ctx.plugin pluginCommand:ctx.command];
pluginController.toggleToolbarVisiblity();
});
$.commands.createCommand("editConstraints", function(ctx){
- var pluginController = MCSConstraintsPluginController.pluginController_(ctx.command);
+ var pluginController = [MCFluidPluginController pluginController:ctx.plugin pluginCommand:ctx.command];
- pluginController.showConstriantInspectorUnderMouse();
+ pluginController.showConstraintInspector();
});
$.commands.createCommand("updateLayout", function(ctx){
- var pluginController = MCSConstraintsPluginController.pluginController_(ctx.command);
+ var pluginController = [MCFluidPluginController pluginController:ctx.plugin pluginCommand:ctx.command];
pluginController.updateLayout();
});
$.commands.createCommand("preview", function(ctx){
- var pluginController = MCSConstraintsPluginController.pluginController_(ctx.command);
+ var pluginController = [MCFluidPluginController pluginController:ctx.plugin pluginCommand:ctx.command];
pluginController.preview();
+});
+
+$.commands.createCommand("toggleArtboardSize", function(ctx){
+ var pluginController = [MCFluidPluginController pluginController:ctx.plugin pluginCommand:ctx.command];
+
+ pluginController.showArtboardSizePresetsPopover();
+});
+
+$.commands.createCommand("showSettingsWindow", function(ctx){
+ var pluginController = [MCFluidPluginController pluginController:ctx.plugin pluginCommand:ctx.command];
+
+ pluginController.showSettingsWindow();
});
@@ -1,11 +1,12 @@
-@import 'SketchLibrary.js'
+@import "SketchLibrary.js"
// Load Bundle
-if($.runtime.classExists("MCSConstraintsPluginController") == false){
+if($.runtime.classExists("MCFluidPluginController") == false){
$.runtime.loadBundle($.paths.resourcesPath+"/MCSketchConstraints.bundle");
-}
-
-// Plugin Methods
-
-// ...
+
+ /*
+ Note to self and whoever else reads these (say hi on twitter :) special word: efficacy):
+ A more robust method for detecting/identifying the existing plugin in the runtime is needed...
+ */
+}

0 comments on commit 06b875c

Please sign in to comment.