From ea21b4f48454fef675d3d1990269e9d7f4c16e99 Mon Sep 17 00:00:00 2001 From: Michael Andreen Date: Fri, 8 Mar 2002 15:24:06 +0000 Subject: [PATCH] some minor ui changes --- bs/bsdoc.cpp | 1 + bs/bsdoc.h | 7 +++++++ bs/bsview.cpp | 7 ++++--- bs/docs/devel/main.doc | 2 +- bs/ui/bsappbase.ui | 14 ++++++++++---- 5 files changed, 23 insertions(+), 8 deletions(-) diff --git a/bs/bsdoc.cpp b/bs/bsdoc.cpp index e3e0469..f26e7e4 100644 --- a/bs/bsdoc.cpp +++ b/bs/bsdoc.cpp @@ -59,6 +59,7 @@ int BSDoc::newBattle(QString name) m_Battles[name]["Friendly"]["Home Planet"]; m_Battles[name]["Hostile"]; + modified = true; emit documentChanged(); return 0; } diff --git a/bs/bsdoc.h b/bs/bsdoc.h index eac45f4..3cca9c3 100644 --- a/bs/bsdoc.h +++ b/bs/bsdoc.h @@ -66,6 +66,13 @@ class BSDoc : public QObject protected: bool modified; + /**This is the main datastructure of the battlecalc, it's more or less the + * core that everything else works around. A short explanation of the fields: + * -# The name of the battle (usually coordinates) + * -# The name of the group (ie. Friendly/Hostile) + * -# The fleetname (Home Planet, coordinates, irc nicks and so on) + * - and in the end you got the actual Fleet object with it's data. + */ std::map > > m_Battles; }; diff --git a/bs/bsview.cpp b/bs/bsview.cpp index 9af428d..1906dda 100644 --- a/bs/bsview.cpp +++ b/bs/bsview.cpp @@ -48,10 +48,11 @@ BSView::BSView(QWidget *parent, BSDoc *doc) : QSplitter(parent) //setting up the listview m_NumberView = new QListView(m_LeftSplit); + m_NumberView->setRootIsDecorated(true); m_NumberView->addColumn("Name"); m_NumberView->addColumn("Number"); m_NumberView->addColumn("ETA"); - addBattle("test"); + //addBattle("NO BATTLES"); m_InfoView = new InfoView(m_LeftSplit); @@ -79,8 +80,8 @@ BSView::~BSView() void BSView::addBattle(QString name) { QListViewItem* battle = new QListViewItem(m_NumberView, name); - QListViewItem* def = new QListViewItem(battle, tr("Defenders"),"", "","1"); - (void) new QListViewItem(battle, tr("Attackers"),"", "","2"); + QListViewItem* def = new QListViewItem(battle, tr("Friendly"),"", "","1"); + (void) new QListViewItem(battle, tr("Hostile"),"", "","2"); (void) new QListViewItem(def, tr("Home Planet"), "","","1"); } diff --git a/bs/docs/devel/main.doc b/bs/docs/devel/main.doc index 37f70f7..fbdf068 100644 --- a/bs/docs/devel/main.doc +++ b/bs/docs/devel/main.doc @@ -2,6 +2,6 @@ \section intro Introduction Going to write something nice here.. (maybe ;) \section cvs Getting CVS access - Yes I got anonymous cvs access, might right how you reach it one day.. ;) + Yes I got anonymous cvs access, might write how you reach it one day.. ;) */ diff --git a/bs/ui/bsappbase.ui b/bs/ui/bsappbase.ui index fa0d859..363fc7e 100644 --- a/bs/ui/bsappbase.ui +++ b/bs/ui/bsappbase.ui @@ -13,7 +13,7 @@ - Form1 + Harvalen's Battlesystem @@ -48,15 +48,15 @@ + + + - - - @@ -319,6 +319,12 @@ New + + Create what's needed to add fleets to a battle + + + Create a new battle with initial groups and home planet + 4194382 -- 2.39.2