Commit 4f69c6e3 authored by coppro's avatar coppro

Updated a few GCC issues, and case-sensitivity of filenames.

I had to rename the export function in Apprentice.cpp since "export" is a reserved word according to the C++ standard. I don't know whether GCC supports it yet, but it certainly complains.
parent dd478d76
......@@ -127,6 +127,7 @@ am_magicseteditor_OBJECTS = ./src/render/text/viewer.$(OBJEXT) \
./src/gui/print_window.$(OBJEXT) \
./src/gui/drop_down_list.$(OBJEXT) \
./src/gui/image_slice_window.$(OBJEXT) \
./src/gui/images_export_window.$(OBJEXT) \
./src/script/script_manager.$(OBJEXT) \
./src/script/script.$(OBJEXT) \
./src/script/functions/basic.$(OBJEXT) \
......@@ -158,11 +159,13 @@ am_magicseteditor_OBJECTS = ./src/render/text/viewer.$(OBJEXT) \
./src/data/action/symbol.$(OBJEXT) \
./src/data/action/set.$(OBJEXT) \
./src/data/action/symbol_part.$(OBJEXT) \
./src/data/action/value.$(OBJEXT) ./src/data/locale.$(OBJEXT) \
./src/data/settings.$(OBJEXT) ./src/data/symbol.$(OBJEXT) \
./src/data/font.$(OBJEXT) ./src/data/game.$(OBJEXT) \
./src/data/card.$(OBJEXT) ./src/data/field.$(OBJEXT) \
./src/data/keyword.$(OBJEXT) ./src/data/stylesheet.$(OBJEXT) \
./src/data/action/value.$(OBJEXT) \
./src/data/action/keyword.$(OBJEXT) \
./src/data/locale.$(OBJEXT) ./src/data/settings.$(OBJEXT) \
./src/data/symbol.$(OBJEXT) ./src/data/font.$(OBJEXT) \
./src/data/game.$(OBJEXT) ./src/data/card.$(OBJEXT) \
./src/data/field.$(OBJEXT) ./src/data/keyword.$(OBJEXT) \
./src/data/stylesheet.$(OBJEXT) \
./src/data/statistics.$(OBJEXT) ./src/data/set.$(OBJEXT) \
./src/data/symbol_font.$(OBJEXT) \
./src/data/export_template.$(OBJEXT) \
......@@ -201,13 +204,13 @@ DIST_ARCHIVES = $(distdir).tar.gz
GZIP_ENV = --best
distuninstallcheck_listfiles = find . -type f -print
distcleancheck_listfiles = find . -type f -print
ACLOCAL = ${SHELL} /home/coppro/C++/MSE/trunk/missing --run aclocal-1.9
ACLOCAL = ${SHELL} /home/coppro/Code/C++/MSE/trunk/missing --run aclocal-1.9
AMDEP_FALSE = #
AMDEP_TRUE =
AMTAR = ${SHELL} /home/coppro/C++/MSE/trunk/missing --run tar
AUTOCONF = ${SHELL} /home/coppro/C++/MSE/trunk/missing --run autoconf
AUTOHEADER = ${SHELL} /home/coppro/C++/MSE/trunk/missing --run autoheader
AUTOMAKE = ${SHELL} /home/coppro/C++/MSE/trunk/missing --run automake-1.9
AMTAR = ${SHELL} /home/coppro/Code/C++/MSE/trunk/missing --run tar
AUTOCONF = ${SHELL} /home/coppro/Code/C++/MSE/trunk/missing --run autoconf
AUTOHEADER = ${SHELL} /home/coppro/Code/C++/MSE/trunk/missing --run autoheader
AUTOMAKE = ${SHELL} /home/coppro/Code/C++/MSE/trunk/missing --run automake-1.9
AWK = mawk
CC = gcc
CCDEPMODE = depmode=gcc3
......@@ -234,7 +237,7 @@ LDFLAGS =
LIBOBJS =
LIBS =
LTLIBOBJS =
MAKEINFO = ${SHELL} /home/coppro/C++/MSE/trunk/missing --run makeinfo
MAKEINFO = ${SHELL} /home/coppro/Code/C++/MSE/trunk/missing --run makeinfo
OBJEXT = o
PACKAGE = magicseteditor
PACKAGE_BUGREPORT = twanvl@users.sourceforge.net
......@@ -278,7 +281,7 @@ host_alias =
htmldir = ${docdir}
includedir = ${prefix}/include
infodir = ${datarootdir}/info
install_sh = /home/coppro/C++/MSE/trunk/install-sh
install_sh = /home/coppro/Code/C++/MSE/trunk/install-sh
libdir = ${exec_prefix}/lib
libexecdir = ${exec_prefix}/libexec
localedir = ${datarootdir}/locale
......@@ -349,6 +352,7 @@ magicseteditor_SOURCES = ./src/render/text/viewer.cpp \
./src/gui/preferences_window.cpp ./src/gui/welcome_window.cpp \
./src/gui/print_window.cpp ./src/gui/drop_down_list.cpp \
./src/gui/image_slice_window.cpp \
./src/gui/images_export_window.cpp \
./src/script/script_manager.cpp ./src/script/script.cpp \
./src/script/functions/basic.cpp \
./src/script/functions/export.cpp \
......@@ -370,19 +374,20 @@ magicseteditor_SOURCES = ./src/render/text/viewer.cpp \
./src/data/format/image_to_symbol.cpp \
./src/data/action/symbol.cpp ./src/data/action/set.cpp \
./src/data/action/symbol_part.cpp ./src/data/action/value.cpp \
./src/data/locale.cpp ./src/data/settings.cpp \
./src/data/symbol.cpp ./src/data/font.cpp ./src/data/game.cpp \
./src/data/card.cpp ./src/data/field.cpp \
./src/data/keyword.cpp ./src/data/stylesheet.cpp \
./src/data/statistics.cpp ./src/data/set.cpp \
./src/data/symbol_font.cpp ./src/data/export_template.cpp \
./src/util/io/get_member.cpp ./src/util/io/reader.cpp \
./src/util/io/package_manager.cpp ./src/util/io/package.cpp \
./src/util/io/writer.cpp ./src/util/rotation.cpp \
./src/util/tagged_string.cpp ./src/util/action_stack.cpp \
./src/util/string.cpp ./src/util/alignment.cpp \
./src/util/version.cpp ./src/util/error.cpp ./src/util/age.cpp \
./src/main.cpp ./src/code_template.cpp
./src/data/action/keyword.cpp ./src/data/locale.cpp \
./src/data/settings.cpp ./src/data/symbol.cpp \
./src/data/font.cpp ./src/data/game.cpp ./src/data/card.cpp \
./src/data/field.cpp ./src/data/keyword.cpp \
./src/data/stylesheet.cpp ./src/data/statistics.cpp \
./src/data/set.cpp ./src/data/symbol_font.cpp \
./src/data/export_template.cpp ./src/util/io/get_member.cpp \
./src/util/io/reader.cpp ./src/util/io/package_manager.cpp \
./src/util/io/package.cpp ./src/util/io/writer.cpp \
./src/util/rotation.cpp ./src/util/tagged_string.cpp \
./src/util/action_stack.cpp ./src/util/string.cpp \
./src/util/alignment.cpp ./src/util/version.cpp \
./src/util/error.cpp ./src/util/age.cpp ./src/main.cpp \
./src/code_template.cpp
all: all-am
.SUFFIXES:
......@@ -689,6 +694,8 @@ src/gui/$(DEPDIR)/$(am__dirstamp):
src/gui/$(DEPDIR)/$(am__dirstamp)
./src/gui/image_slice_window.$(OBJEXT): src/gui/$(am__dirstamp) \
src/gui/$(DEPDIR)/$(am__dirstamp)
./src/gui/images_export_window.$(OBJEXT): src/gui/$(am__dirstamp) \
src/gui/$(DEPDIR)/$(am__dirstamp)
src/script/$(am__dirstamp):
@$(mkdir_p) ./src/script
@: > src/script/$(am__dirstamp)
......@@ -801,6 +808,8 @@ src/data/action/$(DEPDIR)/$(am__dirstamp):
src/data/action/$(DEPDIR)/$(am__dirstamp)
./src/data/action/value.$(OBJEXT): src/data/action/$(am__dirstamp) \
src/data/action/$(DEPDIR)/$(am__dirstamp)
./src/data/action/keyword.$(OBJEXT): src/data/action/$(am__dirstamp) \
src/data/action/$(DEPDIR)/$(am__dirstamp)
src/data/$(am__dirstamp):
@$(mkdir_p) ./src/data
@: > src/data/$(am__dirstamp)
......@@ -888,6 +897,7 @@ magicseteditor$(EXEEXT): $(magicseteditor_OBJECTS) $(magicseteditor_DEPENDENCIES
mostlyclean-compile:
-rm -f *.$(OBJEXT)
-rm -f ./src/code_template.$(OBJEXT)
-rm -f ./src/data/action/keyword.$(OBJEXT)
-rm -f ./src/data/action/set.$(OBJEXT)
-rm -f ./src/data/action/symbol.$(OBJEXT)
-rm -f ./src/data/action/symbol_part.$(OBJEXT)
......@@ -952,6 +962,7 @@ mostlyclean-compile:
-rm -f ./src/gui/drop_down_list.$(OBJEXT)
-rm -f ./src/gui/icon_menu.$(OBJEXT)
-rm -f ./src/gui/image_slice_window.$(OBJEXT)
-rm -f ./src/gui/images_export_window.$(OBJEXT)
-rm -f ./src/gui/new_window.$(OBJEXT)
-rm -f ./src/gui/preferences_window.$(OBJEXT)
-rm -f ./src/gui/print_window.$(OBJEXT)
......@@ -1043,6 +1054,7 @@ include ./src/data/$(DEPDIR)/statistics.Po
include ./src/data/$(DEPDIR)/stylesheet.Po
include ./src/data/$(DEPDIR)/symbol.Po
include ./src/data/$(DEPDIR)/symbol_font.Po
include ./src/data/action/$(DEPDIR)/keyword.Po
include ./src/data/action/$(DEPDIR)/set.Po
include ./src/data/action/$(DEPDIR)/symbol.Po
include ./src/data/action/$(DEPDIR)/symbol_part.Po
......@@ -1080,6 +1092,7 @@ include ./src/gui/$(DEPDIR)/card_select_window.Po
include ./src/gui/$(DEPDIR)/drop_down_list.Po
include ./src/gui/$(DEPDIR)/icon_menu.Po
include ./src/gui/$(DEPDIR)/image_slice_window.Po
include ./src/gui/$(DEPDIR)/images_export_window.Po
include ./src/gui/$(DEPDIR)/new_window.Po
include ./src/gui/$(DEPDIR)/preferences_window.Po
include ./src/gui/$(DEPDIR)/print_window.Po
......
......@@ -89,6 +89,7 @@ magicseteditor_SOURCES += ./src/gui/welcome_window.cpp
magicseteditor_SOURCES += ./src/gui/print_window.cpp
magicseteditor_SOURCES += ./src/gui/drop_down_list.cpp
magicseteditor_SOURCES += ./src/gui/image_slice_window.cpp
magicseteditor_SOURCES += ./src/gui/images_export_window.cpp
magicseteditor_SOURCES += ./src/script/script_manager.cpp
magicseteditor_SOURCES += ./src/script/script.cpp
magicseteditor_SOURCES += ./src/script/functions/basic.cpp
......@@ -124,6 +125,7 @@ magicseteditor_SOURCES += ./src/data/action/symbol.cpp
magicseteditor_SOURCES += ./src/data/action/set.cpp
magicseteditor_SOURCES += ./src/data/action/symbol_part.cpp
magicseteditor_SOURCES += ./src/data/action/value.cpp
magicseteditor_SOURCES += ./src/data/action/keyword.cpp
magicseteditor_SOURCES += ./src/data/locale.cpp
magicseteditor_SOURCES += ./src/data/settings.cpp
magicseteditor_SOURCES += ./src/data/symbol.cpp
......
......@@ -212,12 +212,12 @@ card style:
top : 328
width: 311
height: 142
font:
name: MPlantin
italic name: MPlantin-Italic
size: 14
scale down to: 6
color: rgb(0,0,0)
#font:
# name: MPlantin
# italic name: MPlantin-Italic
# size: 14
# scale down to: 6
# color: rgb(0,0,0)
symbol font:
name:
script:
......
mse version: 0.3.1
mse version: 0.3.1
short name: Magic
full name: Magic the Gathering
icon: card-back.png
......
......@@ -127,7 +127,7 @@ FakeTextValue::FakeTextValue(const TextFieldP& field, String* underlying, bool e
void FakeTextValue::store() {
if (underlying) {
if (editable) {
*underlying = untagged ? untag(value) : value;
*underlying = untagged ? untag(value) : value();
} else {
retrieve();
}
......
......@@ -608,7 +608,7 @@ class ApprenticeExportWindow : public wxDialog, public WithProgress {
void onOk(wxCommandEvent& ev);
/// Export the set
bool export();
bool exportSet();
};
......@@ -689,7 +689,7 @@ void ApprenticeExportWindow::onOk(wxCommandEvent& ev) {
progress_target->Show();
// export!
try {
if (!export()) {
if (!exportSet()) {
// canceled, but allow to try again
progress_target->Hide();
progress_target->Close();
......@@ -706,7 +706,7 @@ void ApprenticeExportWindow::onOk(wxCommandEvent& ev) {
EndModal(wxID_OK);
}
bool ApprenticeExportWindow::export() {
bool ApprenticeExportWindow::exportSet() {
// Expan database
doStep(_("Exporting expansion"), 0.01f);
ApprExpansionDatabase expan(this);
......
......@@ -84,8 +84,8 @@ void KeywordList::onAction(const Action& action, bool undone) {
String match_string(const Keyword& a) {
return untag(replace_all(replace_all(
a.match,
_("<atom-param>"), LEFT_ANGLE_BRACKET),
_("</atom-param>"), RIGHT_ANGLE_BRACKET)
_("<atom-param>"), _("<")),
_("</atom-param>"), _(">"))
);
}
......
......@@ -49,7 +49,11 @@ NewSetWindow::NewSetWindow(Window* parent)
SetSize(630,-1);
// init lists
game_list->showData<Game>();
try {
game_list->select(settings.default_game);
} catch (FileNotFoundError e) {
handle_error(e);
}
UpdateWindowUI(wxUPDATE_UI_RECURSE);
}
......
......@@ -702,7 +702,7 @@ bool TextValueEditor::search(FindInfo& find, bool from_start) {
size_t selection_max = index_to_untagged(value().value(), max(selection_start_i, selection_end_i));
if (find.forward()) {
size_t start = min(v.size(), find.searchSelection() ? selection_min : selection_max);
for (size_t i = start ; i + find.findString().size()) <= v.size() ; ++i) {
for (size_t i = start ; i + find.findString().size() <= v.size() ; ++i) {
if (matchSubstr(v, i, find)) return true;
}
} else {
......
......@@ -174,7 +174,7 @@ struct TextElementsFromString {
line > 0 ? BREAK_LINE : BREAK_HARD);
}
if (bracket) {
e->content = String(LEFT_ANGLE_BRACKET) + c + RIGHT_ANGLE_BRACKET;
e->content = String(_("<")) + c + _(">");
} else {
e->content = c;
}
......
......@@ -428,7 +428,7 @@ String cycle_sort(const String& spec, const String& input) {
* "W1G") -> "1GW" // could be "W...G" or "...GW", second is shorter
* "GRBUWWUG") -> "WWUUBRGG" // no difference by rule 1,2, could be "WUBRG", "UBRGW", etc.
* // becomes _("WUBRG") by rule 3
* "WUR") -> "RWU" // by rule 1 could be "R WU" or "WU R", "RUW" has an earlier hole
* "WUR") -> "RWU" // by rule 1 could be "R WU" or "WU R", "RWU" has an earlier hole
*/
String spec_sort(const String& spec, const String& input) {
String ret;
......@@ -471,7 +471,6 @@ String spec_sort(const String& spec, const String& input) {
return ret;
}
// Sort using spec_sort
class ScriptRule_sort_order: public ScriptValue {
public:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment