Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CATTY-442 Copy Brick with nested Bricks #1622

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/Catty.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1744,6 +1744,7 @@
E4C5C1122143A3150054F236 /* SearchStoreDataSourceTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = E4C5C1112143A3150054F236 /* SearchStoreDataSourceTests.swift */; };
E4E5599820FCD6AD004B4A08 /* StoreProject.swift in Sources */ = {isa = PBXBuildFile; fileRef = E4E5599620FCD6AD004B4A08 /* StoreProject.swift */; };
E5103DEE25CAE67300A32DF8 /* StagePresenterSideMenuView.swift in Sources */ = {isa = PBXBuildFile; fileRef = E5103DED25CAE67300A32DF8 /* StagePresenterSideMenuView.swift */; };
E5635D8625FFB118001E4297 /* BrickCopyTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = E5635D8525FFB118001E4297 /* BrickCopyTests.swift */; };
E564EBE1255D60F5001F0CD0 /* PlayButton.swift in Sources */ = {isa = PBXBuildFile; fileRef = E564EBE0255D60F4001F0CD0 /* PlayButton.swift */; };
E577F0462563C5A400368C18 /* BrickCategoryOverviewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = E577F0452563C5A400368C18 /* BrickCategoryOverviewController.swift */; };
E577F04A2563E8F200368C18 /* BrickCategoryOverviewCollectionViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = E577F0492563E8F200368C18 /* BrickCategoryOverviewCollectionViewCell.swift */; };
Expand Down Expand Up @@ -4186,6 +4187,7 @@
E4E5599620FCD6AD004B4A08 /* StoreProject.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = StoreProject.swift; sourceTree = "<group>"; };
E5103DED25CAE67300A32DF8 /* StagePresenterSideMenuView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StagePresenterSideMenuView.swift; sourceTree = "<group>"; };
E5505707FE2839B02A26E338 /* en-AU */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.strings; name = "en-AU"; path = "en-AU.lproj/Localizable.strings"; sourceTree = "<group>"; };
E5635D8525FFB118001E4297 /* BrickCopyTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BrickCopyTests.swift; sourceTree = "<group>"; };
E564EBE0255D60F4001F0CD0 /* PlayButton.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = PlayButton.swift; sourceTree = "<group>"; };
E57396A397CC08132F593B32 /* en */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/Localizable.strings; sourceTree = "<group>"; };
E577F0452563C5A400368C18 /* BrickCategoryOverviewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BrickCategoryOverviewController.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -5697,6 +5699,7 @@
isa = PBXGroup;
children = (
4C38B3732371522200F33721 /* BrickManagerTests.swift */,
E5635D8525FFB118001E4297 /* BrickCopyTests.swift */,
);
path = BrickManager;
sourceTree = "<group>";
Expand Down Expand Up @@ -11711,6 +11714,7 @@
4C822659213FA7A400F3D750 /* AudioManagerMock.swift in Sources */,
9E4D238C232AF688009D0C3C /* SetColorBrickTests.swift in Sources */,
6F9CF123246E8767008CED1C /* UserListTest.swift in Sources */,
E5635D8625FFB118001E4297 /* BrickCopyTests.swift in Sources */,
D3C6E3A824C8134A00A9E186 /* GoToBrickTests.swift in Sources */,
4CD27AAA21B5765C00DDADB5 /* FeatureMock.swift in Sources */,
4CEB22501B95E47500B3BE2F /* BrickMoveManagerLogicTests.m in Sources */,
Expand Down
11 changes: 11 additions & 0 deletions src/Catty/DataModel/Bricks/Control/LoopBeginBrick.m
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,22 @@

@implementation LoopBeginBrick

- (kBrickCategoryType)category
{
return kControlBrick;
}

- (BOOL)isLoopBrick
{
return YES;
}

#pragma mark - Description
- (NSString*)description
{
return [NSString stringWithFormat:@"Loop Begin Brick"];
}

#pragma mark - Compare
- (BOOL)isEqualToBrick:(Brick*)brick
{
Expand Down
2 changes: 1 addition & 1 deletion src/Catty/DataModel/Bricks/Control/LoopEndBrick.m
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ - (void)performFromScript:(Script*)script
#pragma mark - Description
- (NSString*)description
{
return [NSString stringWithFormat:@"EndLoop"];
return [NSString stringWithFormat:@"Loop End Brick"];
}

#pragma mark - Compare
Expand Down
28 changes: 14 additions & 14 deletions src/Catty/Resources/Localization/en.lproj/Localizable.strings
Original file line number Diff line number Diff line change
Expand Up @@ -169,12 +169,12 @@
/* No comment provided by engineer. */
"Before you can start coding, please read and accept our Privacy Policy to use the app:" = "Before you can start coding, please read and accept our Privacy Policy to use the app:";

/* No comment provided by engineer. */
"blue" = "blue";

/* paint */
"Blue" = "Blue";

/* No comment provided by engineer. */
"blue" = "blue";

/* No comment provided by engineer. */
"Bluetooth is not available. Either your device does not support Bluetooth 4.0 or your Bluetooth chip is damaged. Please check it by connection to another Bluetooth device in the Settings." = "Bluetooth is not available. Either your device does not support Bluetooth 4.0 or your Bluetooth chip is damaged. Please check it by connection to another Bluetooth device in the Settings.";

Expand Down Expand Up @@ -763,12 +763,12 @@
/* No comment provided by engineer. */
"Go to front" = "Go to front";

/* No comment provided by engineer. */
"green" = "green";

/* paint */
"Green" = "Green";

/* No comment provided by engineer. */
"green" = "green";

/* No comment provided by engineer. */
"Guitar" = "Guitar";

Expand Down Expand Up @@ -905,10 +905,10 @@
"left-right only" = "left-right only";

/* No comment provided by engineer. */
"length" = "length";
"Length" = "Length";

/* No comment provided by engineer. */
"Length" = "Length";
"length" = "length";

/* No comment provided by engineer. */
"letter" = "letter";
Expand Down Expand Up @@ -958,12 +958,12 @@
/* No comment provided by engineer. */
"longitude" = "longitude";

/* LOOK */
"look" = "look";

/* No comment provided by engineer. */
"Look" = "Look";

/* LOOK */
"look" = "look";

/* No comment provided by engineer. */
"look name" = "look name";

Expand Down Expand Up @@ -1381,12 +1381,12 @@
/* paint */
"Rectangle / Square" = "Rectangle / Square";

/* paint */
"Red" = "Red";

/* No comment provided by engineer. */
"red" = "red";

/* paint */
"Red" = "Red";

/* No comment provided by engineer. */
"Register" = "Register";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
- (NSInteger)checkEndLoopBrickTypeForDrawing:(BrickCell*)cell;
- (NSArray*)animateWithIndexPath:(NSIndexPath*)path Script:(Script*)script andBrick:(Brick*)brick;
- (NSArray*)scriptCollectionCopyBrickWithIndexPath:(NSIndexPath*)indexPath andBrick:(Brick*)brick;

- (NSArray*)getIndexPathsForRemovingBricks:(NSIndexPath*)indexPath andBrick:(Brick*)brick;

@end
Loading