/*******************************************************************************/ /* Copyright (C) 2008 Jonathan Moore Liles */ /* */ /* 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; see the file COPYING. If not,write to the Free Software */ /* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ /*******************************************************************************/ #include #include #include #include #include // #include #include #include #include #include #include "Scalebar.H" // #include "Waveform.H" #include "Region.H" #include #include #include #include #include #include "Track.H" #include "Audio_Track.H" #include "Timeline.H" #include "Tempo_Track.H" #include "Time_Track.H" #include "Loggable.H" #include "Track_Header.H" #include "const.h" Timeline *timeline; void cb_undo ( Fl_Widget *w, void *v ) { /* static char pat[20]; */ Loggable::undo(); /* sprintf( pat, "undo %d", Loggable::undo_index() ); */ /* w->label( pat ); */ } int main ( int argc, char **argv ) { Fl_Window *main_window = new Fl_Window( 0, 0, 1024, 768 ); Fl::get_system_colors(); Fl::scheme( "plastic" ); Loggable::open( "history" ); /* welcome to C++ */ Loggable::register_create( "Region", &Region::create ); Loggable::register_create( "Tempo_Point", &Tempo_Point::create ); Loggable::register_create( "Time_Point", &Time_Point::create ); Loggable::register_create( "Track_Header", &Track_Header::create ); timeline = new Timeline( 0, 24, main_window->w(), main_window->h() - 24, "Timeline" ); Fl_Button *o = new Fl_Button( 0, 0, 50, 24, "undo" ); o->shortcut( FL_CTRL + 'z' ); o->callback( cb_undo, 0 ); main_window->end(); main_window->show(); Fl::run(); }