1.1 --- a/ornamentedobj.cpp Mon Mar 23 09:06:51 2009 +0000
1.2 +++ b/ornamentedobj.cpp Thu Mar 26 07:49:17 2009 +0000
1.3 @@ -45,10 +45,6 @@
1.4 heading = new HeadingObj(scene);
1.5 heading->move (absPos.x(), absPos.y());
1.6
1.7 - note.setNote("");
1.8 - note.setFontHint (textEditor->getFontHintDefault() );
1.9 - isNoteInEditor=false;
1.10 -
1.11 systemFlags=new FlagRowObj(scene);
1.12 systemFlags->clone(systemFlagsDefault);
1.13 systemFlags->setName ("systemFlags");
1.14 @@ -75,7 +71,6 @@
1.15 heading->copy(other->heading);
1.16 setColor (other->heading->getColor());
1.17
1.18 - note.copy (other->note);
1.19 systemFlags->copy (other->systemFlags);
1.20 standardFlags->copy (other->standardFlags);
1.21
1.22 @@ -260,38 +255,6 @@
1.23 move2RelPos (p.x(),p.y());
1.24 }
1.25
1.26 -void OrnamentedObj::setNote(QString s)
1.27 -{
1.28 - note.setNote(s);
1.29 - updateNoteFlag();
1.30 -}
1.31 -
1.32 -void OrnamentedObj::setNote(NoteObj n)
1.33 -{
1.34 - note=n;
1.35 - updateNoteFlag();
1.36 -}
1.37 -
1.38 -QString OrnamentedObj::getNote()
1.39 -{
1.40 - return note.getNote();
1.41 -}
1.42 -
1.43 -QString OrnamentedObj::getNoteASCII(const QString &indent, const int &width)
1.44 -{
1.45 - return note.getNoteASCII(indent,width);
1.46 -}
1.47 -
1.48 -QString OrnamentedObj::getNoteASCII()
1.49 -{
1.50 - return note.getNoteASCII();
1.51 -}
1.52 -
1.53 -QString OrnamentedObj::getNoteOpenDoc()
1.54 -{
1.55 - return note.getNoteOpenDoc();
1.56 -}
1.57 -
1.58 void OrnamentedObj::setURL(QString s)
1.59 {
1.60 url=s;
1.61 @@ -407,20 +370,25 @@
1.62 return false;
1.63 }
1.64
1.65 -void OrnamentedObj::getNoteFromTextEditor ()
1.66 +/* FIXME-3 should move to VymView ?! void OrnamentedObj::getNoteFromTextEditor ()
1.67 {
1.68 note.setFilenameHint (textEditor->getFilename());
1.69 note.setFontHint (textEditor->getFontHint() );
1.70 setNote( textEditor->getText() );
1.71 }
1.72 +*/
1.73
1.74 -void OrnamentedObj::updateNoteFlag()
1.75 +void OrnamentedObj::updateSystemFlags()
1.76 {
1.77 - bool noteEmpty;
1.78 + // FIXME-3 check if note here and text in editor are still in sync!!
1.79 + // Best would be to always have current text here...
1.80 + bool noteEmpty=treeItem->getNoteObj().isEmpty();
1.81 + /*
1.82 if (isNoteInEditor)
1.83 noteEmpty=textEditor->isEmpty();
1.84 else
1.85 noteEmpty=note.isEmpty();
1.86 + */
1.87
1.88 if (!noteEmpty)
1.89 {
1.90 @@ -432,12 +400,11 @@
1.91 if (!systemFlags->isActive ("note")) return;
1.92 systemFlags->deactivate("note");
1.93 }
1.94 - model->setChanged();
1.95 + //model->setChanged();
1.96 calcBBoxSize();
1.97 positionBBox();
1.98 move (absPos.x(), absPos.y() );
1.99 forceReposition();
1.100 -
1.101 }
1.102
1.103 void OrnamentedObj::updateFlagsToolbar()