Changeset e43c8d0 in thomson for elec/CrO2/software/gui.cpp
- Timestamp:
- Mar 24, 2012, 3:26:03 PM (12 years ago)
- Branches:
- main
- Children:
- 4a558d7
- Parents:
- fe55aa5
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
elec/CrO2/software/gui.cpp
rfe55aa5 re43c8d0 108 108 IupSetAttribute(hexEd, "ALIGNMENT", "ALEFT"); 109 109 Callback<Gui, const char*, int, int>::create(hexEd, "VALUE_CB", this, &Gui::matVal); 110 Callback<Gui, int, int, int, const char*>::create(hexEd, "VALUE_EDIT_CB", this, &Gui::setMatVal); 110 111 111 112 // WINDOW LAYOUT … … 227 228 return IUP_DEFAULT; 228 229 } 230 231 232 int Gui::setMatVal(int x, int y, const char* val) 233 { 234 int pos = (y-1) * 16 + (x-1); 235 236 if (file == NULL || selblock < 0 || selblock >= file->getBlockCount()) 237 return 0; 238 239 const Tape::Block& block = file->getBlock(selblock); 240 block.data[pos] = 0; // TODO parse hex val to int 241 242 return 0; 243 } 244 229 245 230 246 const char* Gui::matVal(int y, int x)
Note:
See TracChangeset
for help on using the changeset viewer.