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

Use navbar instead of tab bar controller. #941

Merged
merged 4 commits into from
Jun 2, 2020
Merged
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
60 changes: 49 additions & 11 deletions src/darwin/CHIPTool/CHIPTool.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
objects = {

/* Begin PBXBuildFile section */
0CA0E0CF248599BB009087B9 /* OnOffViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 0CA0E0CE248599BB009087B9 /* OnOffViewController.m */; };
991DC091247747F500C13860 /* EchoViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 991DC090247747F500C13860 /* EchoViewController.m */; };
B204A621244E1D0600C7C0E1 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = B204A620244E1D0600C7C0E1 /* AppDelegate.m */; };
B204A624244E1D0600C7C0E1 /* SceneDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = B204A623244E1D0600C7C0E1 /* SceneDelegate.m */; };
Expand Down Expand Up @@ -44,15 +45,17 @@
/* End PBXCopyFilesBuildPhase section */

/* Begin PBXFileReference section */
991DC08F247747F500C13860 /* EchoViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = EchoViewController.h; path = UI/EchoViewController.h; sourceTree = "<group>"; };
991DC090247747F500C13860 /* EchoViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = EchoViewController.m; path = UI/EchoViewController.m; sourceTree = "<group>"; };
0CA0E0CD248599BB009087B9 /* OnOffViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = OnOffViewController.h; sourceTree = "<group>"; };
0CA0E0CE248599BB009087B9 /* OnOffViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = OnOffViewController.m; sourceTree = "<group>"; };
991DC08F247747F500C13860 /* EchoViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = EchoViewController.h; sourceTree = "<group>"; };
991DC090247747F500C13860 /* EchoViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = EchoViewController.m; sourceTree = "<group>"; };
B204A61C244E1D0600C7C0E1 /* CHIPTool.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = CHIPTool.app; sourceTree = BUILT_PRODUCTS_DIR; };
B204A61F244E1D0600C7C0E1 /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = UI/AppDelegate.h; sourceTree = "<group>"; };
B204A620244E1D0600C7C0E1 /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = AppDelegate.m; path = UI/AppDelegate.m; sourceTree = "<group>"; };
B204A622244E1D0600C7C0E1 /* SceneDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = SceneDelegate.h; path = UI/SceneDelegate.h; sourceTree = "<group>"; };
B204A623244E1D0600C7C0E1 /* SceneDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = SceneDelegate.m; path = UI/SceneDelegate.m; sourceTree = "<group>"; };
B204A625244E1D0600C7C0E1 /* QRCodeViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = QRCodeViewController.h; path = UI/QRCodeViewController.h; sourceTree = "<group>"; };
B204A626244E1D0600C7C0E1 /* QRCodeViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = QRCodeViewController.m; path = UI/QRCodeViewController.m; sourceTree = "<group>"; };
B204A625244E1D0600C7C0E1 /* QRCodeViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = QRCodeViewController.h; sourceTree = "<group>"; };
B204A626244E1D0600C7C0E1 /* QRCodeViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = QRCodeViewController.m; sourceTree = "<group>"; };
B204A62B244E1D0700C7C0E1 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
B204A630244E1D0700C7C0E1 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
B204A631244E1D0700C7C0E1 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
Expand Down Expand Up @@ -82,6 +85,33 @@
/* End PBXFrameworksBuildPhase section */

/* Begin PBXGroup section */
0C79937824858B3B0047A373 /* QRCode */ = {
isa = PBXGroup;
children = (
B204A625244E1D0600C7C0E1 /* QRCodeViewController.h */,
B204A626244E1D0600C7C0E1 /* QRCodeViewController.m */,
);
path = QRCode;
sourceTree = "<group>";
};
0C79937924858B4F0047A373 /* Echo client */ = {
isa = PBXGroup;
children = (
991DC08F247747F500C13860 /* EchoViewController.h */,
991DC090247747F500C13860 /* EchoViewController.m */,
);
path = "Echo client";
sourceTree = "<group>";
};
0CA0E0D0248599C4009087B9 /* OnOffCluster */ = {
isa = PBXGroup;
children = (
0CA0E0CD248599BB009087B9 /* OnOffViewController.h */,
0CA0E0CE248599BB009087B9 /* OnOffViewController.m */,
);
path = OnOffCluster;
sourceTree = "<group>";
};
B20252DE2459EC7600F97062 /* Frameworks */ = {
isa = PBXGroup;
children = (
Expand Down Expand Up @@ -112,6 +142,7 @@
B204A61E244E1D0600C7C0E1 /* CHIPTool */ = {
isa = PBXGroup;
children = (
B204A62B244E1D0700C7C0E1 /* Assets.xcassets */,
B2F53AEC245B0D190010745E /* Main.storyboard */,
B2F53AE9245B0D140010745E /* LaunchScreen.storyboard */,
B204A630244E1D0700C7C0E1 /* Info.plist */,
Expand All @@ -120,11 +151,9 @@
B204A620244E1D0600C7C0E1 /* AppDelegate.m */,
B204A622244E1D0600C7C0E1 /* SceneDelegate.h */,
B204A623244E1D0600C7C0E1 /* SceneDelegate.m */,
B204A625244E1D0600C7C0E1 /* QRCodeViewController.h */,
B204A626244E1D0600C7C0E1 /* QRCodeViewController.m */,
B204A62B244E1D0700C7C0E1 /* Assets.xcassets */,
991DC08F247747F500C13860 /* EchoViewController.h */,
991DC090247747F500C13860 /* EchoViewController.m */,
0C79937824858B3B0047A373 /* QRCode */,
0C79937924858B4F0047A373 /* Echo client */,
0CA0E0D0248599C4009087B9 /* OnOffCluster */,
);
path = CHIPTool;
sourceTree = "<group>";
Expand Down Expand Up @@ -243,6 +272,7 @@
B204A621244E1D0600C7C0E1 /* AppDelegate.m in Sources */,
B204A632244E1D0700C7C0E1 /* main.m in Sources */,
B204A624244E1D0600C7C0E1 /* SceneDelegate.m in Sources */,
0CA0E0CF248599BB009087B9 /* OnOffViewController.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down Expand Up @@ -398,8 +428,9 @@
B204A64C244E1D0700C7C0E1 /* Debug iOS */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = arm64;
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_IDENTITY = "iPhone Developer";
CODE_SIGN_IDENTITY = "-";
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO;
Expand All @@ -408,18 +439,22 @@
"$(inherited)",
"@executable_path/Frameworks",
);
ONLY_ACTIVE_ARCH = YES;
PRODUCT_BUNDLE_IDENTIFIER = com.chip.CHIPTool;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
SDKROOT = iphoneos.internal;
TARGETED_DEVICE_FAMILY = "1,2";
VALID_ARCHS = "arm64 armv4t armv5 armv6 armv6m armv7 armv7em armv7f armv7k armv7m armv7s xscale";
};
name = "Debug iOS";
};
B204A64D244E1D0700C7C0E1 /* Release iOS */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = arm64;
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_IDENTITY = "iPhone Developer";
CODE_SIGN_IDENTITY = "-";
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO;
Expand All @@ -428,10 +463,13 @@
"$(inherited)",
"@executable_path/Frameworks",
);
ONLY_ACTIVE_ARCH = YES;
PRODUCT_BUNDLE_IDENTIFIER = com.chip.CHIPTool;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
SDKROOT = iphoneos.internal;
TARGETED_DEVICE_FAMILY = "1,2";
VALID_ARCHS = "arm64 armv4t armv5 armv6 armv6m armv7 armv7em armv7f armv7k armv7m armv7s xscale";
};
name = "Release iOS";
};
Expand Down
17 changes: 17 additions & 0 deletions src/darwin/CHIPTool/CHIPTool/OnOffCluster/OnOffViewController.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
//
// OnOffViewController.h
// CHIPTool
//
// Created by Bhaskar on 6/1/20.
// Copyright © 2020 CHIP. All rights reserved.
//

#import <UIKit/UIKit.h>

NS_ASSUME_NONNULL_BEGIN

@interface OnOffViewController : UIViewController

@end

NS_ASSUME_NONNULL_END
47 changes: 47 additions & 0 deletions src/darwin/CHIPTool/CHIPTool/OnOffCluster/OnOffViewController.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
//
// OnOffViewController.m
// CHIPTool
//
// Created by Bhaskar on 6/1/20.
// Copyright © 2020 CHIP. All rights reserved.
//

#import "OnOffViewController.h"

@interface OnOffViewController ()

@end

@implementation OnOffViewController

- (void)viewDidLoad
{
[super viewDidLoad];
// Do any additional setup after loading the view.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
// Get the new view controller using [segue destinationViewController].
// Pass the selected object to the new view controller.
}
*/
- (IBAction)onButtonTapped:(id)sender
{
NSLog(@"On tapped");
}

- (IBAction)offButtonTapped:(id)sender
{
NSLog(@"Off tapped");
}

- (IBAction)toggleButtonTapped:(id)sender
{
NSLog(@"Toggle tapped");
}

@end
Loading