18 Boolean isUserLoggedIn;
30 - (instancetype) initWithDelegate:(
id<V7GoogDriveControlDelegate>) dele andFrame: (CGRect)frame
32 self = [
super initWithFrame:frame];
35 [
self setClipsToBounds:YES];
36 NSLog(
@"Z7GoogDriveControlbar.initWithDelegate: (%@) finish init", NSStringFromClass([
delegate class]));
41 #pragma mark - Z6ContainedView 47 - (void) appear:(CGRect)bound
49 float viewWidth = bound.size.width;
50 NSLog(
@"Z7GoogDriveControlBar.appear: bound: %3.2f/%3.2f %3.2f/%3.2f",
51 bound.origin.x, bound.origin.y, bound.size.width, bound.size.height);
53 buttonSize = CGSizeMake(viewWidth * 0.50 - 4.0, 40.0);
57 - (void) fillViewOnAppearance: (CGRect) parentBound
59 float viewWidth = parentBound.size.width;
60 NSLog(
@"Z7GoogDriveControlBar.fillViewForDelegate: viewWidth: %3.2f", viewWidth);
61 buttonSize = CGSizeMake(viewWidth * 0.5, 40.0);
65 [
self setBackgroundColor:[UIColor orangeColor]];
68 [
self setBackgroundColor:[UIColor yellowColor]];
74 CGRect totalFrame =
self.frame;
75 float buttonWidth = 160.0;
80 CGRect signInButtonFrame = CGRectMake(totalFrame.size.width - buttonWidth - 12.0,
83 totalFrame.size.height -4.0);
93 _signInButton.layer.cornerRadius = 8;
94 _signInButton.layer.borderColor = [[UIColor blackColor] CGColor];
95 _signInButton.layer.borderWidth = 3.0;
96 _signInButton .clipsToBounds = YES;
98 NSLog(
@"Z7GoogDriveControlBar.placeLoginButton: init/size: %3.2f %3.2f", [_signInButton frame].size.width, [_signInButton frame].size.height);
99 [_signInButton setFrame:signInButtonFrame];
100 [
self addSubview:_signInButton];
102 - (void) userLoggedIn:(BOOL) flag
104 isUserLoggedIn = flag;
105 [_signInButton setHidden:flag];
107 - (void) showRecipeOption:(Boolean)flag
113 NSLog(
@"Z7GoogDriveControlBar: clickRecipeButton");
id< GIDSignInDelegate > delegate
CGRect controlbarLeftButtonFrame
UIButton * controlbarRightButton
id< V7GoogDriveControlDelegate > delegate
instancetype sharedInstance()
UIButton * controlbarLeftButton
void fillViewOnAppearance:(CGRect parentBound)
UIButton * controlbarRecipeButton
CGRect controlbarRightButtonFrame
id< GIDSignInUIDelegate > uiDelegate
Singleton interface to both core and remote data sources.
GIDSignIn * sharedInstance()
void configureGoogleSignIn()
float heightRequirement()