/elec/propeller-clock

To get this branch, use:
bzr branch http://bzr.ed.am/elec/propeller-clock

« back to all changes in this revision

Viewing changes to src/modes/settings_major_mode.cc

  • Committer: Tim Marston
  • Date: 2012-05-18 18:29:50 UTC
  • Revision ID: tim@ed.am-20120518182950-t85bn9a21n72uzm8
text messages are now individually enabled and draw()n automatically

Show diffs side-by-side

added added

removed removed

33
33
#define DATE_SET_IDX 2
34
34
 
35
35
 
36
 
void SettingsMajorMode::draw( int segment )
 
36
SettingsMajorMode::SettingsMajorMode( Button &button )
 
37
        :
 
38
        _button( button )
37
39
{
38
 
        Text::draw( 0, segment );
39
40
}
40
41
 
41
42
 
94
95
                break;
95
96
        }
96
97
 
97
 
        Text::set_message( 0, str0 );
 
98
        Text::set_message_text( 0, str0 );
98
99
}
99
100
 
100
101
 
103
104
        _item = _part = 0;
104
105
 
105
106
        reset_messages();
 
107
 
 
108
        _button.set_press_mode( false );
106
109
}
107
110
 
108
111
 
109
112
void SettingsMajorMode::deactivate()
110
113
{
 
114
        _button.set_press_mode( true );
 
115
 
 
116
        // save time
 
117
 
111
118
}
112
119
 
113
120
 
158
165
 
159
166
void SettingsMajorMode::reset_messages()
160
167
{
161
 
        Text::reset_message( 0, Text::MODE_TOP | Text::MODE_ALL );
 
168
        Text::reset();
 
169
 
 
170
        Text::set_up_message( 0, Text::MODE_TOP | Text::MODE_ALL );
162
171
}