Rename fapp.{cpp,h} to fapplication.{cpp,h}
This commit is contained in:
parent
aad380ca6f
commit
3f8b9d774b
|
@ -39,6 +39,7 @@ test/input-dialog
|
|||
test/choice
|
||||
test/listbox
|
||||
test/listview
|
||||
test/treeview
|
||||
test/mandelbrot
|
||||
test/keyboard
|
||||
test/mouse
|
||||
|
|
|
@ -38,8 +38,3 @@ script:
|
|||
|
||||
sudo: required
|
||||
|
||||
after_success:
|
||||
- curl https://copilot.blackducksoftware.com/scripts/init/gradle -o bds_init.gradle
|
||||
- ./gradlew --init-script bds_init.gradle buildBom -DbdsPluginVersion=5.0.2
|
||||
- bash <(curl -s https://copilot.blackducksoftware.com/bash/travis) ./build/blackduck/*_bdio.jsonld
|
||||
|
||||
|
|
|
@ -1,3 +1,6 @@
|
|||
2017-08-24 Markus Gans <guru.mail@muenster.de>
|
||||
* Rename fapp.{cpp,h} to fapplication.{cpp,h}
|
||||
|
||||
2017-08-20 Markus Gans <guru.mail@muenster.de>
|
||||
* Screen characters got a union structure for a faster
|
||||
attribute compare operation
|
||||
|
|
|
@ -45,7 +45,7 @@ libfinal_la_SOURCES = \
|
|||
foptiattr.cpp \
|
||||
foptimove.cpp \
|
||||
ftermbuffer.cpp \
|
||||
fapp.cpp \
|
||||
fapplication.cpp \
|
||||
fwidget.cpp \
|
||||
fobject.cpp
|
||||
|
||||
|
@ -54,7 +54,7 @@ libfinal_la_LDFLAGS = -version-info @SO_VERSION@
|
|||
finalcutincludedir = $(includedir)/final
|
||||
|
||||
finalcutinclude_HEADERS = \
|
||||
fapp.h \
|
||||
fapplication.h \
|
||||
fbutton.h \
|
||||
fbuttongroup.h \
|
||||
fcharmap.h \
|
||||
|
|
|
@ -8,7 +8,7 @@ MAJOR := $(shell echo ${VERSION} | cut -d. -f1)
|
|||
LIBDIR = /usr/local/lib64
|
||||
INCLUDEDIR = /usr/local/include/final
|
||||
INCLUDE_HEADERS = \
|
||||
fapp.h \
|
||||
fapplication.h \
|
||||
fbuttongroup.h \
|
||||
fbutton.h \
|
||||
fcheckbox.h \
|
||||
|
@ -95,7 +95,7 @@ OBJS = \
|
|||
foptiattr.o \
|
||||
foptimove.o \
|
||||
ftermbuffer.o \
|
||||
fapp.o \
|
||||
fapplication.o \
|
||||
fwidget.o \
|
||||
fobject.o
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@ MAJOR := $(shell echo ${VERSION} | cut -d. -f1)
|
|||
LIBDIR = /usr/local/lib64
|
||||
INCLUDEDIR = /usr/local/include/final
|
||||
INCLUDE_HEADERS = \
|
||||
fapp.h \
|
||||
fapplication.h \
|
||||
fbuttongroup.h \
|
||||
fbutton.h \
|
||||
fcheckbox.h \
|
||||
|
@ -95,7 +95,7 @@ OBJS = \
|
|||
foptiattr.o \
|
||||
foptimove.o \
|
||||
ftermbuffer.o \
|
||||
fapp.o \
|
||||
fapplication.o \
|
||||
fwidget.o \
|
||||
fobject.o
|
||||
|
||||
|
|
|
@ -136,7 +136,8 @@ am_libfinal_la_OBJECTS = fstring.lo fpoint.lo frect.lo fscrollbar.lo \
|
|||
fmenulist.lo fdialog.lo fscrollview.lo fwindow.lo \
|
||||
fmessagebox.lo ftooltip.lo ffiledialog.lo ftextview.lo \
|
||||
fstatusbar.lo fterm.lo fvterm.lo fevent.lo foptiattr.lo \
|
||||
foptimove.lo ftermbuffer.lo fapp.lo fwidget.lo fobject.lo
|
||||
foptimove.lo ftermbuffer.lo fapplication.lo fwidget.lo \
|
||||
fobject.lo
|
||||
libfinal_la_OBJECTS = $(am_libfinal_la_OBJECTS)
|
||||
AM_V_lt = $(am__v_lt_@AM_V@)
|
||||
am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
|
||||
|
@ -411,14 +412,14 @@ libfinal_la_SOURCES = \
|
|||
foptiattr.cpp \
|
||||
foptimove.cpp \
|
||||
ftermbuffer.cpp \
|
||||
fapp.cpp \
|
||||
fapplication.cpp \
|
||||
fwidget.cpp \
|
||||
fobject.cpp
|
||||
|
||||
libfinal_la_LDFLAGS = -version-info @SO_VERSION@
|
||||
finalcutincludedir = $(includedir)/final
|
||||
finalcutinclude_HEADERS = \
|
||||
fapp.h \
|
||||
fapplication.h \
|
||||
fbutton.h \
|
||||
fbuttongroup.h \
|
||||
fcharmap.h \
|
||||
|
@ -544,7 +545,7 @@ mostlyclean-compile:
|
|||
distclean-compile:
|
||||
-rm -f *.tab.c
|
||||
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fapp.Plo@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fapplication.Plo@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fbutton.Plo@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fbuttongroup.Plo@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fcheckbox.Plo@am__quote@
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: fapplication.cpp
|
||||
// Provides: class FApplication
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fmenu.h"
|
||||
#include "fstatusbar.h"
|
||||
#include "fwindow.h"
|
|
@ -1,7 +1,7 @@
|
|||
// File: fbutton.cpp
|
||||
// Provides: class FButton
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fbutton.h"
|
||||
#include "fstatusbar.h"
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: fbuttongroup.cpp
|
||||
// Provides: class FButtonGroup
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fbuttongroup.h"
|
||||
#include "fstatusbar.h"
|
||||
#include "ftogglebutton.h"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: fdialog.cpp
|
||||
// Provides: class FDialog
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fdialog.h"
|
||||
#include "fstatusbar.h"
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
#ifndef FINAL_H
|
||||
#define FINAL_H
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fbuttongroup.h"
|
||||
#include "fbutton.h"
|
||||
#include "fcheckbox.h"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: flabel.cpp
|
||||
// Provides: class FLabel
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "flabel.h"
|
||||
#include "fstatusbar.h"
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: flineedit.cpp
|
||||
// Provides: class FLineEdit
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "flineedit.h"
|
||||
#include "fstatusbar.h"
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
// Provides: class FListBoxItem
|
||||
// class FListBox
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "flistbox.h"
|
||||
#include "fscrollbar.h"
|
||||
#include "fstatusbar.h"
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
// Provides: class FListViewItem
|
||||
// class FListView
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "flistview.h"
|
||||
#include "fscrollbar.h"
|
||||
#include "fstatusbar.h"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: fmenu.cpp
|
||||
// Provides: class FMenu
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fdialog.h"
|
||||
#include "fmenu.h"
|
||||
#include "fstatusbar.h"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: fmenubar.cpp
|
||||
// Provides: class FMenuBar
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fmenubar.h"
|
||||
#include "fstatusbar.h"
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: fmenuitem.cpp
|
||||
// Provides: class FMenuItem
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fdialog.h"
|
||||
#include "fmenu.h"
|
||||
#include "fmenubar.h"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: fmessagebox.cpp
|
||||
// Provides: class FMessageBox
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fmessagebox.h"
|
||||
|
||||
|
||||
|
|
|
@ -64,7 +64,7 @@ class FObject
|
|||
virtual const char* getClassName() const;
|
||||
FObject* getParent() const;
|
||||
FObject* getChild (int) const;
|
||||
FObjectList getChildren() const;
|
||||
const FObjectList& getChildren() const;
|
||||
int numOfChildren() const;
|
||||
|
||||
// Inquiries
|
||||
|
@ -133,7 +133,7 @@ inline FObject* FObject::getParent() const
|
|||
{ return parent_obj; }
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
inline FObject::FObjectList FObject::getChildren() const
|
||||
inline const FObject::FObjectList& FObject::getChildren() const
|
||||
{ return children_list; }
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: fradiobutton.cpp
|
||||
// Provides: class FRadioButton
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fradiobutton.h"
|
||||
|
||||
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
#ifndef FTEXTVIEW_H
|
||||
#define FTEXTVIEW_H
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fscrollbar.h"
|
||||
#include "fstatusbar.h"
|
||||
#include "fstring.h"
|
||||
|
@ -62,7 +62,7 @@ class FTextView : public FWidget
|
|||
uInt getColumns() const;
|
||||
uInt getRows() const;
|
||||
const FString getText() const;
|
||||
stringLines getLines() const;
|
||||
const stringLines& getLines() const;
|
||||
|
||||
// Mutators
|
||||
void setGeometry (int, int, int, int, bool = true);
|
||||
|
@ -134,7 +134,7 @@ inline uInt FTextView::getRows() const
|
|||
{ return uInt(data.size()); }
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
inline FTextView::stringLines FTextView::getLines() const
|
||||
inline const FTextView::stringLines& FTextView::getLines() const
|
||||
{ return data; }
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: ftogglebutton.cpp
|
||||
// Provides: class FToggleButton
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fbuttongroup.h"
|
||||
#include "fstatusbar.h"
|
||||
#include "ftogglebutton.h"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: ftooltip.cpp
|
||||
// Provides: class FToolTip
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "ftooltip.h"
|
||||
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: fvterm.cpp
|
||||
// Provides: class FVTerm
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fvterm.h"
|
||||
#include "fwidget.h"
|
||||
#include "fwindow.h"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: fwidget.cpp
|
||||
// Provides: class FWidget
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fmenubar.h"
|
||||
#include "fstatusbar.h"
|
||||
#include "fwidget.h"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: fwindow.cpp
|
||||
// Provides: class FWindow
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fmenubar.h"
|
||||
#include "fstatusbar.h"
|
||||
#include "fwindow.h"
|
||||
|
|
|
@ -12,6 +12,7 @@ noinst_PROGRAMS = \
|
|||
choice \
|
||||
listbox \
|
||||
listview \
|
||||
treeview \
|
||||
opti-move \
|
||||
termcap \
|
||||
string-operations \
|
||||
|
@ -34,6 +35,7 @@ input_dialog_SOURCES = input-dialog.cpp
|
|||
choice_SOURCES = choice.cpp
|
||||
listbox_SOURCES = listbox.cpp
|
||||
listview_SOURCES = listview.cpp
|
||||
treeview_SOURCES = treeview.cpp
|
||||
opti_move_SOURCES = opti-move.cpp
|
||||
string_operations_SOURCES = string-operations.cpp
|
||||
mandelbrot_SOURCES = mandelbrot.cpp
|
||||
|
|
|
@ -84,11 +84,12 @@ build_triplet = @build@
|
|||
host_triplet = @host@
|
||||
noinst_PROGRAMS = hello$(EXEEXT) dialog$(EXEEXT) input-dialog$(EXEEXT) \
|
||||
choice$(EXEEXT) listbox$(EXEEXT) listview$(EXEEXT) \
|
||||
opti-move$(EXEEXT) termcap$(EXEEXT) string-operations$(EXEEXT) \
|
||||
mandelbrot$(EXEEXT) calculator$(EXEEXT) watch$(EXEEXT) \
|
||||
term-attributes$(EXEEXT) transparent$(EXEEXT) \
|
||||
keyboard$(EXEEXT) mouse$(EXEEXT) timer$(EXEEXT) \
|
||||
scrollview$(EXEEXT) windows$(EXEEXT) menu$(EXEEXT) ui$(EXEEXT)
|
||||
treeview$(EXEEXT) opti-move$(EXEEXT) termcap$(EXEEXT) \
|
||||
string-operations$(EXEEXT) mandelbrot$(EXEEXT) \
|
||||
calculator$(EXEEXT) watch$(EXEEXT) term-attributes$(EXEEXT) \
|
||||
transparent$(EXEEXT) keyboard$(EXEEXT) mouse$(EXEEXT) \
|
||||
timer$(EXEEXT) scrollview$(EXEEXT) windows$(EXEEXT) \
|
||||
menu$(EXEEXT) ui$(EXEEXT)
|
||||
subdir = test
|
||||
DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
|
||||
$(top_srcdir)/depcomp
|
||||
|
@ -162,6 +163,9 @@ timer_LDADD = $(LDADD)
|
|||
am_transparent_OBJECTS = transparent.$(OBJEXT)
|
||||
transparent_OBJECTS = $(am_transparent_OBJECTS)
|
||||
transparent_LDADD = $(LDADD)
|
||||
am_treeview_OBJECTS = treeview.$(OBJEXT)
|
||||
treeview_OBJECTS = $(am_treeview_OBJECTS)
|
||||
treeview_LDADD = $(LDADD)
|
||||
am_ui_OBJECTS = ui.$(OBJEXT)
|
||||
ui_OBJECTS = $(am_ui_OBJECTS)
|
||||
ui_LDADD = $(LDADD)
|
||||
|
@ -211,8 +215,8 @@ SOURCES = $(calculator_SOURCES) $(choice_SOURCES) $(dialog_SOURCES) \
|
|||
$(menu_SOURCES) $(mouse_SOURCES) $(opti_move_SOURCES) \
|
||||
$(scrollview_SOURCES) $(string_operations_SOURCES) \
|
||||
$(term_attributes_SOURCES) $(termcap_SOURCES) $(timer_SOURCES) \
|
||||
$(transparent_SOURCES) $(ui_SOURCES) $(watch_SOURCES) \
|
||||
$(windows_SOURCES)
|
||||
$(transparent_SOURCES) $(treeview_SOURCES) $(ui_SOURCES) \
|
||||
$(watch_SOURCES) $(windows_SOURCES)
|
||||
DIST_SOURCES = $(calculator_SOURCES) $(choice_SOURCES) \
|
||||
$(dialog_SOURCES) $(hello_SOURCES) $(input_dialog_SOURCES) \
|
||||
$(keyboard_SOURCES) $(listbox_SOURCES) $(listview_SOURCES) \
|
||||
|
@ -220,7 +224,8 @@ DIST_SOURCES = $(calculator_SOURCES) $(choice_SOURCES) \
|
|||
$(opti_move_SOURCES) $(scrollview_SOURCES) \
|
||||
$(string_operations_SOURCES) $(term_attributes_SOURCES) \
|
||||
$(termcap_SOURCES) $(timer_SOURCES) $(transparent_SOURCES) \
|
||||
$(ui_SOURCES) $(watch_SOURCES) $(windows_SOURCES)
|
||||
$(treeview_SOURCES) $(ui_SOURCES) $(watch_SOURCES) \
|
||||
$(windows_SOURCES)
|
||||
am__can_run_installinfo = \
|
||||
case $$AM_UPDATE_INFO_DIR in \
|
||||
n|no|NO) false;; \
|
||||
|
@ -376,6 +381,7 @@ input_dialog_SOURCES = input-dialog.cpp
|
|||
choice_SOURCES = choice.cpp
|
||||
listbox_SOURCES = listbox.cpp
|
||||
listview_SOURCES = listview.cpp
|
||||
treeview_SOURCES = treeview.cpp
|
||||
opti_move_SOURCES = opti-move.cpp
|
||||
string_operations_SOURCES = string-operations.cpp
|
||||
mandelbrot_SOURCES = mandelbrot.cpp
|
||||
|
@ -507,6 +513,10 @@ transparent$(EXEEXT): $(transparent_OBJECTS) $(transparent_DEPENDENCIES) $(EXTRA
|
|||
@rm -f transparent$(EXEEXT)
|
||||
$(AM_V_CXXLD)$(CXXLINK) $(transparent_OBJECTS) $(transparent_LDADD) $(LIBS)
|
||||
|
||||
treeview$(EXEEXT): $(treeview_OBJECTS) $(treeview_DEPENDENCIES) $(EXTRA_treeview_DEPENDENCIES)
|
||||
@rm -f treeview$(EXEEXT)
|
||||
$(AM_V_CXXLD)$(CXXLINK) $(treeview_OBJECTS) $(treeview_LDADD) $(LIBS)
|
||||
|
||||
ui$(EXEEXT): $(ui_OBJECTS) $(ui_DEPENDENCIES) $(EXTRA_ui_DEPENDENCIES)
|
||||
@rm -f ui$(EXEEXT)
|
||||
$(AM_V_CXXLD)$(CXXLINK) $(ui_OBJECTS) $(ui_LDADD) $(LIBS)
|
||||
|
@ -543,6 +553,7 @@ distclean-compile:
|
|||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/termcap.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timer.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/transparent.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/treeview.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ui.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/watch.Po@am__quote@
|
||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/windows.Po@am__quote@
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
#include <limits>
|
||||
#include <stack>
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fdialog.h"
|
||||
#include "fmessagebox.h"
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// File: os-choice.cpp
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fbutton.h"
|
||||
#include "fbuttongroup.h"
|
||||
#include "fdialog.h"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// File: dialog.cpp
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fbutton.h"
|
||||
#include "fdialog.h"
|
||||
#include "flabel.h"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// File: hello.cpp
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fmessagebox.h"
|
||||
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// File: input-dialog.cpp
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fbutton.h"
|
||||
#include "fbuttongroup.h"
|
||||
#include "fcheckbox.h"
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
#include <iostream>
|
||||
#include <fstream>
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fdialog.h"
|
||||
#include "flistbox.h"
|
||||
#include "fmessagebox.h"
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
#include <iostream>
|
||||
#include <fstream>
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fdialog.h"
|
||||
#include "flistview.h"
|
||||
#include "fmessagebox.h"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// File: mandelbrot.cpp
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fdialog.h"
|
||||
#include "fmessagebox.h"
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// File: menu.cpp
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fcheckmenuitem.h"
|
||||
#include "fdialog.h"
|
||||
#include "flabel.h"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// File: mouse.cpp
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fdialog.h"
|
||||
#include "flabel.h"
|
||||
#include "fmessagebox.h"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
// File: opti-move.cpp
|
||||
|
||||
#include <iomanip>
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fvterm.h"
|
||||
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// File: scrollview.cpp
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fbutton.h"
|
||||
#include "fdialog.h"
|
||||
#include "flabel.h"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// File: term-attributes.cpp
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fbutton.h"
|
||||
#include "fdialog.h"
|
||||
#include "fmessagebox.h"
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
#include <iomanip>
|
||||
#include <iostream>
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "ftermcap.h"
|
||||
#include "fvterm.h"
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// File: transparent.cpp
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fdialog.h"
|
||||
#include "flabel.h"
|
||||
#include "fmessagebox.h"
|
||||
|
|
|
@ -0,0 +1,141 @@
|
|||
// File: treeview.cpp
|
||||
|
||||
#include <iostream>
|
||||
#include <fstream>
|
||||
|
||||
#include "fapplication.h"
|
||||
#include "fdialog.h"
|
||||
#include "flistview.h"
|
||||
#include "fmessagebox.h"
|
||||
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
// class Treeview
|
||||
//----------------------------------------------------------------------
|
||||
|
||||
#pragma pack(push)
|
||||
#pragma pack(1)
|
||||
|
||||
class Treeview : public FDialog
|
||||
{
|
||||
public:
|
||||
// Constructor
|
||||
explicit Treeview (FWidget* = 0);
|
||||
// Destructor
|
||||
~Treeview();
|
||||
|
||||
private:
|
||||
// Disable copy constructor
|
||||
Treeview (const Treeview&);
|
||||
// Disable assignment operator (=)
|
||||
Treeview& operator = (const Treeview&);
|
||||
|
||||
// Event handlers
|
||||
void onClose (FCloseEvent*);
|
||||
|
||||
// Callback methods
|
||||
void cb_exitApp (FWidget*, data_ptr);
|
||||
};
|
||||
#pragma pack(pop)
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
Treeview::Treeview (FWidget* parent)
|
||||
: FDialog(parent)
|
||||
{
|
||||
// Create FListView object
|
||||
FListView* listView = new FListView (this);
|
||||
listView->setGeometry(2, 1, 33, 14);
|
||||
|
||||
// Add columns to the view
|
||||
listView->addColumn ("Name");
|
||||
listView->addColumn ("Population");
|
||||
listView->addColumn ("Density/km²");
|
||||
|
||||
// Set right alignment for the second and third column
|
||||
listView->setColumnAlignment (2, fc::alignRight);
|
||||
listView->setColumnAlignment (3, fc::alignRight);
|
||||
|
||||
// Populate FListView with a list of items
|
||||
std::string continent[][3] =
|
||||
{
|
||||
{ "Africa", "944,000,000", "31.2" },
|
||||
{ "Asia", "4,010,000,000", "90.3" },
|
||||
{ "Europe", "733,000,000", "69.9" },
|
||||
{ "North America", "523,000,000", "21" },
|
||||
{ "South America", "381,000,000", "21.4" },
|
||||
{ "Antarctica", "1000", "0" },
|
||||
{ "Australia/Oceania", "34,000,000", "4" }
|
||||
};
|
||||
|
||||
const int lastItem = int(sizeof(continent) / sizeof(continent[0])) - 1;
|
||||
|
||||
for (int i=0; i <= lastItem; i++)
|
||||
{
|
||||
std::vector<FString> line (&continent[i][0], &continent[i][0] + 3);
|
||||
listView->insert (line);
|
||||
}
|
||||
|
||||
// Quit button
|
||||
FButton* Quit = new FButton (this);
|
||||
Quit->setGeometry(24, 16, 10, 1);
|
||||
Quit->setText (L"&Quit");
|
||||
|
||||
// Add some function callbacks
|
||||
Quit->addCallback
|
||||
(
|
||||
"clicked",
|
||||
F_METHOD_CALLBACK (this, &Treeview::cb_exitApp)
|
||||
);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
Treeview::~Treeview()
|
||||
{ }
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
void Treeview::onClose (FCloseEvent* ev)
|
||||
{
|
||||
int ret = FMessageBox::info ( this, "Quit"
|
||||
, "Do you really want\n"
|
||||
"to quit the program ?"
|
||||
, FMessageBox::Yes
|
||||
, FMessageBox::No );
|
||||
if ( ret == FMessageBox::Yes )
|
||||
ev->accept();
|
||||
else
|
||||
ev->ignore();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
void Treeview::cb_exitApp (FWidget*, data_ptr)
|
||||
{
|
||||
close();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
// main part
|
||||
//----------------------------------------------------------------------
|
||||
|
||||
int main (int argc, char* argv[])
|
||||
{
|
||||
if ( argv[1] && ( std::strcmp(argv[1], "--help") == 0
|
||||
|| std::strcmp(argv[1], "-h") == 0 ) )
|
||||
{
|
||||
std::cout << "Generic options:" << std::endl
|
||||
<< " -h, --help "
|
||||
<< "Display this help and exit" << std::endl;
|
||||
FApplication::print_cmd_Options();
|
||||
std::exit(EXIT_SUCCESS);
|
||||
}
|
||||
|
||||
FApplication app(argc, argv);
|
||||
|
||||
Treeview d(&app);
|
||||
d.setText (L"Continents");
|
||||
d.setGeometry (int(1 + (app.getWidth() - 37) / 2), 3, 37, 20);
|
||||
d.setShadow();
|
||||
|
||||
app.setMainWidget(&d);
|
||||
d.show();
|
||||
return app.exec();
|
||||
}
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
#include <ctime>
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "flabel.h"
|
||||
#include "fdialog.h"
|
||||
#include "fmessagebox.h"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// File: windows.cpp
|
||||
|
||||
#include "fapp.h"
|
||||
#include "fapplication.h"
|
||||
#include "fdialog.h"
|
||||
#include "fdialoglistmenu.h"
|
||||
#include "flabel.h"
|
||||
|
|
Loading…
Reference in New Issue