Changeset 184:4e8704aae278 in glemon-0.x for mapstorage.cc
- Timestamp:
- 01/10/07 15:37:46 (18 years ago)
- Branch:
- default
- Phase:
- public
- Convert:
- svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/glemon/trunk@3125
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
mapstorage.cc
r177 r184 18 18 19 19 #include "mapstorage.h" 20 #include "nbtab.h" 20 21 #include "gui_writer.h" 21 22 #include "gui_reader.h" … … 28 29 const double p_d=40000; 29 30 30 MapStorage::MapStorage( ) : modified(false), file_name(""), arrow_pos_read_ok(false), iterations(i_d), attraction(a_d), propulsation(p_d)31 MapStorage::MapStorage(NoteBookTab& tab) : mytab(tab), modified(false), file_name(""), arrow_pos_read_ok(false), iterations(i_d), attraction(a_d), propulsation(p_d), background_set(false) 31 32 { 32 33 nodemap_storage["coordinates_x"] = new Graph::NodeMap<double>(graph); … … 553 554 signal_design_win.emit(attraction, propulsation, iterations); 554 555 } 556 557 void MapStorage::setBackground(const std::string& file_name) 558 { 559 if (file_name == background_file_name) return; 560 if (file_name == "") 561 { 562 background_file_name = ""; 563 background_set = false; 564 } 565 else 566 { 567 background_file_name = file_name; 568 background_set = true; 569 } 570 mytab.gd_canvas->setBackground(); 571 } 572 573 const std::string& MapStorage::getBackgroundFilename() 574 { 575 return background_file_name; 576 } 577 578 bool MapStorage::isBackgroundSet() 579 { 580 return background_set; 581 } 582 583 double MapStorage::getBackgroundScaling() 584 { 585 return background_scaling; 586 } 587 588 void MapStorage::setBackgroundScaling(double scaling) 589 { 590 background_scaling = scaling; 591 }
Note: See TracChangeset
for help on using the changeset viewer.