Ignore:
Timestamp:
Dec 24, 2009, 4:17:54 AM (10 years ago)
Author:
sven
Message:

Punch Card Editor, ongoing development

  • Extended new Deck interface, expanding the undo framework
  • Implemented editor changes via undo framework
  • revised the menu and toolbar actions and structure (now dynamic construction at deck load time), implemented undo viewer
  • Started implementation of device driver framework in menu
  • Embedded the Qextserialport library (http://qextserialport.sourceforge.net/)
  • Started the Documation M200 Client device driver (well, just created the directory structure and qmake project file infrastructure)
  • At the current state, the complete project compiles :-)

Statistics: About 3500 Lines of code (without libqextserialport)

-- sven @ workstation

File:
1 edited

Legend:

Unmodified
Added
Removed
  • punch-card/punch-card-editor/src/text/editor.cc

    r52 r53  
    229229        // start translation
    230230        qDebug() << "starting translation";
    231         codec->fromAscii(text, &main->deck->at( card_index ) );
    232         qDebug("Translated successfully");
     231        Card translated;
     232        codec->fromAscii(text, &translated); //&main->deck->at( card_index ) );
     233        qDebug("Translation done. Creating undo command");
     234
     235        DeckModifyCard* command = new DeckModifyCard(main->deck, card_index, translated);
     236        command->setText(tr("Set card %1 content using codec %2 to '%3'").arg(card_index).arg("CodecName").arg(text));
     237        main->deck->run(command, true);
     238
     239        qDebug("Command executed.");
     240
    233241        // urhm... that was all the magic.
    234242        // send "you were changed" thingy! :-)
    235         main->deck->emitChanged(card_index, card_index);
     243        //main->deck->emitChanged(card_index, card_index);
     244        // no. that does the command!
    236245        return true;
    237246}
Note: See TracChangeset for help on using the changeset viewer.
© 2008 - 2013 technikum29 • Sven Köppel • Some rights reserved
Powered by Trac
Expect where otherwise noted, content on this site is licensed under a Creative Commons 3.0 License