Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

dragToMove and dragToDelete implemented #5

Closed
wants to merge 7 commits into from

2 participants

@ghost

i added 2 BOOL properties to the HSImageSidebarView Class, dragToMove and dragToDelete, so that can be disabled\enabled Moving and Deleting behiavour

@bjhomer
Owner

Mostly looks good.

A few notes:

  • I think dragToMove and dragToDelete should be YES by default to ensure backward compatibility for anyone already using the project. They should be able to update to the latest version without making any other changes to their code.
  • The first commit in this pull request doesn't compile on its own. (That's why you added the second one, understood.) It would be nice if we could squash those two commits together into one, so that the commit history is cleaner. If you're not familiar with changing history in git, it's really worth learning. See http://help.github.com/rebase/ for a place to start. If you're just too hesitant to do that, I could just do it myself, but it's a good learning opportunity for you, and it's not really that hard.
  • The last commit message talks about dragToEnable, which isn't a thing. :) So again, here's an opportunity to use git rebase -i

I still need to actually check out the project with your changes and look at it more closely. I'll probably do that later today. But from what I could see in the github diff viewer, it looks pretty good.

@bjhomer
Owner

It appears that if dragToDelete = YES and dragToMove = NO, then when you drag something but don't drag to delete it, then the cell remains partially transparent. I'll probably just patch it up myself and merge it in directly. But I thought I'd let you know.

@ghost ghost closed this
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jan 9, 2012
Commits on Jan 11, 2012
  1. @danydev

    Revert "updated sample to assign new BOOLs dragToMove and dragToEnable"

    danydev authored
    This reverts commit 6912709b5849c62abd656f9be7831745ca314d92.
  2. @danydev

    Revert "Update sample proj file and resize demo view controller corre…

    danydev authored
    …ctly."
    
    This reverts commit 44c00dc186bb32645e03b84a841b22d9ebf3c4b4.
  3. @danydev
  4. @danydev

    project fix to run on ipad

    danydev authored
This page is out of date. Refresh to see the latest.
View
57 Resources/en.lproj/SidebarViewController.xib
@@ -1,14 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<archive type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="8.00">
<data>
- <int key="IBDocument.SystemTarget">1280</int>
- <string key="IBDocument.SystemVersion">11C74</string>
- <string key="IBDocument.InterfaceBuilderVersion">1938</string>
- <string key="IBDocument.AppKitVersion">1138.23</string>
- <string key="IBDocument.HIToolboxVersion">567.00</string>
+ <int key="IBDocument.SystemTarget">1056</int>
+ <string key="IBDocument.SystemVersion">10J567</string>
+ <string key="IBDocument.InterfaceBuilderVersion">1294</string>
+ <string key="IBDocument.AppKitVersion">1038.35</string>
+ <string key="IBDocument.HIToolboxVersion">462.00</string>
<object class="NSMutableDictionary" key="IBDocument.PluginVersions">
<string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
- <string key="NS.object.0">933</string>
+ <string key="NS.object.0">294</string>
</object>
<array key="IBDocument.IntegratedClassDependencies">
<string>IBProxyObject</string>
@@ -18,10 +18,7 @@
<array key="IBDocument.PluginDependencies">
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
</array>
- <object class="NSMutableDictionary" key="IBDocument.Metadata">
- <string key="NS.key.0">PluginDependencyRecalculationVersion</string>
- <integer value="1" key="NS.object.0"/>
- </object>
+ <dictionary class="NSMutableDictionary" key="IBDocument.Metadata"/>
<array class="NSMutableArray" key="IBDocument.RootObjects" id="1000">
<object class="IBProxyObject" id="841351856">
<string key="IBProxiedObjectIdentifier">IBFilesOwner</string>
@@ -50,7 +47,7 @@
</object>
<object class="IBUIButton" id="496310911">
<reference key="NSNextResponder" ref="766721923"/>
- <int key="NSvFlags">303</int>
+ <int key="NSvFlags">295</int>
<string key="NSFrame">{{400, 350}, {194, 37}}</string>
<reference key="NSSuperview" ref="766721923"/>
<reference key="NSWindow"/>
@@ -59,6 +56,11 @@
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
<int key="IBUIContentHorizontalAlignment">0</int>
<int key="IBUIContentVerticalAlignment">0</int>
+ <object class="NSFont" key="IBUIFont" id="706254075">
+ <string key="NSName">Helvetica-Bold</string>
+ <double key="NSSize">15</double>
+ <int key="NSfFlags">16</int>
+ </object>
<int key="IBUIButtonType">1</int>
<string key="IBUINormalTitle">Delete</string>
<object class="NSColor" key="IBUIHighlightedTitleColor" id="256320820">
@@ -73,21 +75,10 @@
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MC41AA</bytes>
</object>
- <object class="IBUIFontDescription" key="IBUIFontDescription" id="387078752">
- <string key="name">Helvetica-Bold</string>
- <string key="family">Helvetica</string>
- <int key="traits">2</int>
- <double key="pointSize">15</double>
- </object>
- <object class="NSFont" key="IBUIFont" id="706254075">
- <string key="NSName">Helvetica-Bold</string>
- <double key="NSSize">15</double>
- <int key="NSfFlags">16</int>
- </object>
</object>
<object class="IBUIButton" id="798373514">
<reference key="NSNextResponder" ref="766721923"/>
- <int key="NSvFlags">303</int>
+ <int key="NSvFlags">295</int>
<string key="NSFrame">{{158, 350}, {194, 37}}</string>
<reference key="NSSuperview" ref="766721923"/>
<reference key="NSWindow"/>
@@ -96,6 +87,7 @@
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
<int key="IBUIContentHorizontalAlignment">0</int>
<int key="IBUIContentVerticalAlignment">0</int>
+ <reference key="IBUIFont" ref="706254075"/>
<int key="IBUIButtonType">1</int>
<string key="IBUINormalTitle">Insert</string>
<reference key="IBUIHighlightedTitleColor" ref="256320820"/>
@@ -104,8 +96,6 @@
<bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes>
</object>
<reference key="IBUINormalTitleShadowColor" ref="820338797"/>
- <reference key="IBUIFontDescription" ref="387078752"/>
- <reference key="IBUIFont" ref="706254075"/>
</object>
</array>
<string key="NSFrame">{{0, 20}, {768, 1004}}</string>
@@ -145,21 +135,21 @@
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchEventConnection" key="connection">
- <string key="label">deleteSelection:</string>
- <reference key="source" ref="496310911"/>
+ <string key="label">insertRow:</string>
+ <reference key="source" ref="798373514"/>
<reference key="destination" ref="841351856"/>
<int key="IBEventType">7</int>
</object>
- <int key="connectionID">14</int>
+ <int key="connectionID">13</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchEventConnection" key="connection">
- <string key="label">insertRow:</string>
- <reference key="source" ref="798373514"/>
+ <string key="label">deleteSelection:</string>
+ <reference key="source" ref="496310911"/>
<reference key="destination" ref="841351856"/>
<int key="IBEventType">7</int>
</object>
- <int key="connectionID">13</int>
+ <int key="connectionID">14</int>
</object>
</array>
<object class="IBMutableOrderedSet" key="objectRecords">
@@ -210,10 +200,9 @@
</object>
<dictionary class="NSMutableDictionary" key="flattenedProperties">
<string key="-1.CustomClassName">SidebarViewController</string>
- <string key="-1.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="-2.CustomClassName">UIResponder</string>
- <string key="-2.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="11.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="2.IBEditorWindowLastContentRect">{{513, 0}, {783, 856}}</string>
<string key="2.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="4.CustomClassName">HSImageSidebarView</string>
<string key="4.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
@@ -274,6 +263,6 @@
<string key="IBDocument.TargetRuntimeIdentifier">IBIPadFramework</string>
<bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>
<int key="IBDocument.defaultPropertyAccessControl">3</int>
- <string key="IBCocoaTouchPluginVersion">933</string>
+ <string key="IBCocoaTouchPluginVersion">294</string>
</data>
</archive>
View
6 Sidebar.xcodeproj/project.pbxproj
@@ -260,7 +260,7 @@
B7B8053A129393C400EBE69D /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
- ARCHS = "$(ARCHS_STANDARD_32_BIT)";
+ ARCHS = "$(ARCHS_UNIVERSAL_IPHONE_OS)";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
@@ -278,7 +278,7 @@
B7B8053B129393C400EBE69D /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
- ARCHS = "$(ARCHS_STANDARD_32_BIT)";
+ ARCHS = "$(ARCHS_UNIVERSAL_IPHONE_OS)";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
@@ -313,6 +313,7 @@
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "Sidebar-Prefix.pch";
INFOPLIST_FILE = "Resources/Sidebar-Info.plist";
+ IPHONEOS_DEPLOYMENT_TARGET = 4.2;
LINKER_DISPLAYS_MANGLED_NAMES = YES;
PRODUCT_NAME = "$(TARGET_NAME)";
TARGETED_DEVICE_FAMILY = "1,2";
@@ -328,6 +329,7 @@
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "Sidebar-Prefix.pch";
INFOPLIST_FILE = "Resources/Sidebar-Info.plist";
+ IPHONEOS_DEPLOYMENT_TARGET = 4.2;
LINKER_DISPLAYS_MANGLED_NAMES = YES;
PRODUCT_NAME = "$(TARGET_NAME)";
TARGETED_DEVICE_FAMILY = "1,2";
Something went wrong with that request. Please try again.