X-Git-Url: http://git.cinelerra-gg.org/git/?p=goodguy%2Fhistory.git;a=blobdiff_plain;f=cinelerra-5.1%2Fcinelerra%2Ftimeentry.C;h=f8ccf00017502db398ca7c61a1688ff5b816a091;hp=586daaaf8b3c4965e202df36263f9b8cd841ea52;hb=502b6f3b6fd04f6b01c6d70dcb81aa304dd0db1c;hpb=0b78779e9e75131eee81d2e4689b98df0e91c092 diff --git a/cinelerra-5.1/cinelerra/timeentry.C b/cinelerra-5.1/cinelerra/timeentry.C index 586daaaf..f8ccf000 100644 --- a/cinelerra-5.1/cinelerra/timeentry.C +++ b/cinelerra-5.1/cinelerra/timeentry.C @@ -2,28 +2,28 @@ /* * CINELERRA * Copyright (C) 2008 Adam Williams - * + * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - * + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * + * */ #include "timeentry.h" #include "language.h" #include -TimeEntry::TimeEntry(BC_WindowBase *gui, int x, int y, +TimeEntry::TimeEntry(BC_WindowBase *gui, int x, int y, int *output_day, double *output_time, int time_format, int time_w) { @@ -46,7 +46,7 @@ TimeEntry::~TimeEntry() delete day_tumbler; delete time_text; } -const char* TimeEntry::day_table[] = +const char* TimeEntry::day_table[] = { N_("Sun"), N_("Mon"), N_("Tue"), N_("Wed"), N_("Thu"), N_("Fri"), N_("Sat"), "*" }; @@ -88,7 +88,7 @@ void TimeEntry::create_objects() char string[BCTEXTLEN]; if(output_day) { - day_text = new DayText(this, x, y, 50, + day_text = new DayText(this, x, y, 50, day_table, TOTAL_DAYS, day_table[*output_day]); gui->add_subwindow(day_text); x += day_text->get_w(); @@ -99,7 +99,7 @@ void TimeEntry::create_objects() time_w -= day_tumbler->get_w(); } - time_text = new TimeTextBox(this, x, y, time_w, + time_text = new TimeTextBox(this, x, y, time_w, Units::totext(string, *output_time, time_format)); gui->add_subwindow(time_text); @@ -139,7 +139,7 @@ void TimeEntry::reposition_window(int x, int y) int time_w = this->time_w; this->x = x; this->y = y; - + if(day_text) { day_text->reposition_window(x, y); x += day_text->get_w(); @@ -150,7 +150,7 @@ void TimeEntry::reposition_window(int x, int y) x += day_tumbler->get_w(); time_w -= day_tumbler->get_w(); } - + time_text->reposition_window(x, y, time_w); } @@ -189,8 +189,8 @@ int TimeEntry::handle_event() -DayText::DayText(TimeEntry *timeentry, - int x, int y, int w, +DayText::DayText(TimeEntry *timeentry, + int x, int y, int w, const char **table, int table_items, const char *text) : BC_TextBox(x, y, w, 1, _(text)) @@ -319,7 +319,7 @@ int SecTumbler::handle_down_event() -TimeTextBox::TimeTextBox(TimeEntry *timeentry, +TimeTextBox::TimeTextBox(TimeEntry *timeentry, int x, int y, int w, char *default_text) : BC_TextBox(x, y, w, 1, default_text) {