Changeset 0a45bc8 in orbit for iOS/Orbit/Orbit/controllers


Ignore:
Timestamp:
12/30/13 00:00:31 (9 years ago)
Author:
Steve Castellotti <sc@…>
Branches:
master, Servo
Children:
7f21a20
Parents:
57848ad
Message:
  • Presets buttons added (Hover, Forward, Left and Right)
Location:
iOS/Orbit/Orbit/controllers
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • iOS/Orbit/Orbit/controllers/AdvancedViewController.h

    r57848ad r0a45bc8  
    1515 
    1616@property (nonatomic, retain) IBOutlet UIBarButtonItem *resetButton; 
     17 
    1718@property (nonatomic, retain) IBOutlet UILabel *throttlePercent; 
    1819@property (nonatomic, retain) IBOutlet UISlider *throttle; 
     
    2122@property (nonatomic, retain) IBOutlet UILabel *pitchPercent; 
    2223@property (nonatomic, retain) IBOutlet UISlider *pitch; 
     24 
     25@property (nonatomic, retain) IBOutlet UILabel *presets; 
     26@property (nonatomic, retain) IBOutlet UIButton *buttonHover; 
     27@property (nonatomic, retain) IBOutlet UIButton *buttonForward; 
     28@property (nonatomic, retain) IBOutlet UIButton *buttonLeft; 
     29@property (nonatomic, retain) IBOutlet UIButton *buttonRight; 
     30 
    2331@property (nonatomic, retain) IBOutlet UILabel *tiltSensorControl; 
    2432@property (nonatomic, retain) IBOutlet UISwitch *switchTiltSensorControl; 
     
    3240- (IBAction) throttleChanged:(id)sender; 
    3341 
     42- (IBAction) hoverButtonPressed:(id)sender; 
     43- (IBAction) forwardButtonPressed:(id)sender; 
     44- (IBAction) leftButtonPressed:(id)sender; 
     45- (IBAction) rightButtonPressed:(id)sender; 
     46 
    3447- (IBAction)changeSwitchTiltSensorControl:(id)sender; 
    3548- (IBAction)changeSwitchTiltSensorControlThrottle:(id)sender; 
  • iOS/Orbit/Orbit/controllers/AdvancedViewController.m

    r4a94f92 r0a45bc8  
    3333//   [alert show]; 
    3434      
     35} 
     36 
     37- (IBAction) resetButtonPressed:(id)button 
     38{ 
     39   pitch.value = 0.5; 
     40   yaw.value = 0.5; 
     41   throttle.value = 0.5; 
     42   NSString *zero = @"0%"; 
     43   throttlePercent.text = zero; 
     44   yawPercent.text = zero; 
     45   pitchPercent.text = zero; 
     46   [self adjustValues]; 
    3547} 
    3648 
     
    7890} 
    7991 
    80 - (IBAction) resetButtonPressed:(id)button 
    81 { 
    82     pitch.value = 0.5; 
    83     yaw.value = 0.5; 
    84     throttle.value = 0.5; 
    85     NSString *zero = @"0%"; 
    86     throttlePercent.text = zero; 
    87     yawPercent.text = zero; 
    88     pitchPercent.text = zero; 
    89     [self adjustValues]; 
     92- (IBAction) hoverButtonPressed:(id)sender { 
     93   NSLog(@"DEBUG: hoverButtonPressed"); 
    9094} 
     95 
     96- (IBAction) forwardButtonPressed:(id)sender { 
     97   NSLog(@"DEBUG: forwardButtonPressed"); 
     98} 
     99 
     100- (IBAction) leftButtonPressed:(id)sender { 
     101   NSLog(@"DEBUG: leftButtonPressed"); 
     102} 
     103 
     104- (IBAction) rightButtonPressed:(id)sender { 
     105   NSLog(@"DEBUG: rightButtonPressed"); 
     106} 
     107 
     108 
    91109 
    92110- (IBAction)changeSwitchTiltSensorControl:(id)sender{ 
Note: See TracChangeset for help on using the changeset viewer.