mirror of
https://github.com/TermiT/Flycut.git
synced 2025-10-04 19:05:28 +08:00
Merge pull request #42 from denizt/dev
Add merge all, and fix the empty item bug
This commit is contained in:
commit
457b4541e0
7 changed files with 662 additions and 3496 deletions
|
@ -69,6 +69,7 @@
|
||||||
-(void) stackUp;
|
-(void) stackUp;
|
||||||
-(void) stackDown;
|
-(void) stackDown;
|
||||||
-(IBAction)clearClippingList:(id)sender;
|
-(IBAction)clearClippingList:(id)sender;
|
||||||
|
-(IBAction)mergeClippingList:(id)sender;
|
||||||
|
|
||||||
// Stack related
|
// Stack related
|
||||||
-(BOOL) isValidClippingNumber:(NSNumber *)number;
|
-(BOOL) isValidClippingNumber:(NSNumber *)number;
|
||||||
|
|
|
@ -519,6 +519,11 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
-(IBAction)mergeClippingList:(id)sender {
|
||||||
|
[clippingStore mergeList];
|
||||||
|
[self updateMenu];
|
||||||
|
}
|
||||||
|
|
||||||
- (void)updateMenu {
|
- (void)updateMenu {
|
||||||
|
|
||||||
NSArray *returnedDisplayStrings = [clippingStore previousDisplayStrings:[[DBUserDefaults standardUserDefaults] integerForKey:@"displayNum"]];
|
NSArray *returnedDisplayStrings = [clippingStore previousDisplayStrings:[[DBUserDefaults standardUserDefaults] integerForKey:@"displayNum"]];
|
||||||
|
|
4133
English.lproj/MainMenu.nib/designable.nib
generated
4133
English.lproj/MainMenu.nib/designable.nib
generated
File diff suppressed because it is too large
Load diff
BIN
English.lproj/MainMenu.nib/keyedobjects.nib
generated
BIN
English.lproj/MainMenu.nib/keyedobjects.nib
generated
Binary file not shown.
|
@ -439,7 +439,7 @@
|
||||||
29B97313FDCFA39411CA2CEA /* Project object */ = {
|
29B97313FDCFA39411CA2CEA /* Project object */ = {
|
||||||
isa = PBXProject;
|
isa = PBXProject;
|
||||||
attributes = {
|
attributes = {
|
||||||
LastUpgradeCheck = 0410;
|
LastUpgradeCheck = 0500;
|
||||||
};
|
};
|
||||||
buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "Flycut" */;
|
buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "Flycut" */;
|
||||||
compatibilityVersion = "Xcode 3.2";
|
compatibilityVersion = "Xcode 3.2";
|
||||||
|
@ -531,6 +531,7 @@
|
||||||
C01FCF4B08A954540054247B /* Debug */ = {
|
C01FCF4B08A954540054247B /* Debug */ = {
|
||||||
isa = XCBuildConfiguration;
|
isa = XCBuildConfiguration;
|
||||||
buildSettings = {
|
buildSettings = {
|
||||||
|
COMBINE_HIDPI_IMAGES = YES;
|
||||||
COPY_PHASE_STRIP = NO;
|
COPY_PHASE_STRIP = NO;
|
||||||
FRAMEWORK_SEARCH_PATHS = (
|
FRAMEWORK_SEARCH_PATHS = (
|
||||||
"$(FRAMEWORK_SEARCH_PATHS)",
|
"$(FRAMEWORK_SEARCH_PATHS)",
|
||||||
|
@ -551,7 +552,7 @@
|
||||||
C01FCF4C08A954540054247B /* Release */ = {
|
C01FCF4C08A954540054247B /* Release */ = {
|
||||||
isa = XCBuildConfiguration;
|
isa = XCBuildConfiguration;
|
||||||
buildSettings = {
|
buildSettings = {
|
||||||
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
|
COMBINE_HIDPI_IMAGES = YES;
|
||||||
FRAMEWORK_SEARCH_PATHS = (
|
FRAMEWORK_SEARCH_PATHS = (
|
||||||
"$(FRAMEWORK_SEARCH_PATHS)",
|
"$(FRAMEWORK_SEARCH_PATHS)",
|
||||||
"$(SRCROOT)",
|
"$(SRCROOT)",
|
||||||
|
@ -570,11 +571,11 @@
|
||||||
C01FCF4F08A954540054247B /* Debug */ = {
|
C01FCF4F08A954540054247B /* Debug */ = {
|
||||||
isa = XCBuildConfiguration;
|
isa = XCBuildConfiguration;
|
||||||
buildSettings = {
|
buildSettings = {
|
||||||
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
|
|
||||||
CODE_SIGN_IDENTITY = "";
|
CODE_SIGN_IDENTITY = "";
|
||||||
GCC_C_LANGUAGE_STANDARD = c99;
|
GCC_C_LANGUAGE_STANDARD = c99;
|
||||||
GCC_WARN_ABOUT_RETURN_TYPE = YES;
|
GCC_WARN_ABOUT_RETURN_TYPE = YES;
|
||||||
GCC_WARN_UNUSED_VARIABLE = YES;
|
GCC_WARN_UNUSED_VARIABLE = YES;
|
||||||
|
ONLY_ACTIVE_ARCH = YES;
|
||||||
PRODUCT_NAME = Flycut;
|
PRODUCT_NAME = Flycut;
|
||||||
SDKROOT = macosx;
|
SDKROOT = macosx;
|
||||||
};
|
};
|
||||||
|
@ -583,7 +584,6 @@
|
||||||
C01FCF5008A954540054247B /* Release */ = {
|
C01FCF5008A954540054247B /* Release */ = {
|
||||||
isa = XCBuildConfiguration;
|
isa = XCBuildConfiguration;
|
||||||
buildSettings = {
|
buildSettings = {
|
||||||
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
|
|
||||||
CODE_SIGN_IDENTITY = "";
|
CODE_SIGN_IDENTITY = "";
|
||||||
GCC_C_LANGUAGE_STANDARD = c99;
|
GCC_C_LANGUAGE_STANDARD = c99;
|
||||||
GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
|
GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
|
||||||
|
|
|
@ -78,6 +78,9 @@
|
||||||
// Delete all list clippings
|
// Delete all list clippings
|
||||||
-(void) clearList;
|
-(void) clearList;
|
||||||
|
|
||||||
|
// Merge all list clippings
|
||||||
|
-(void) mergeList;
|
||||||
|
|
||||||
// Move the clipping at index to the top
|
// Move the clipping at index to the top
|
||||||
-(void) clippingMoveToTop:(int)index;
|
-(void) clippingMoveToTop:(int)index;
|
||||||
|
|
||||||
|
|
|
@ -51,6 +51,9 @@
|
||||||
|
|
||||||
// Add a clipping
|
// Add a clipping
|
||||||
-(void) addClipping:(NSString *)clipping ofType:(NSString *)type{
|
-(void) addClipping:(NSString *)clipping ofType:(NSString *)type{
|
||||||
|
if ([clipping length] == 0) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
// Clipping object
|
// Clipping object
|
||||||
JumpcutClipping * newClipping;
|
JumpcutClipping * newClipping;
|
||||||
// Create clipping
|
// Create clipping
|
||||||
|
@ -84,6 +87,11 @@
|
||||||
jcList = emptyJCList;
|
jcList = emptyJCList;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
-(void) mergeList {
|
||||||
|
NSString *merge = [[[[jcList reverseObjectEnumerator] allObjects] valueForKey:@"clipContents"] componentsJoinedByString:@"\n"];
|
||||||
|
[self addClipping:merge ofType:NSStringFromClass([merge class])];
|
||||||
|
}
|
||||||
|
|
||||||
-(void) clearItem:(int)index
|
-(void) clearItem:(int)index
|
||||||
{
|
{
|
||||||
[jcList removeObjectAtIndex:index];
|
[jcList removeObjectAtIndex:index];
|
||||||
|
|
Loading…
Add table
Reference in a new issue