/[svn]/gigedit/trunk/src/gigedit/dimregionchooser.cpp
ViewVC logotype

Diff of /gigedit/trunk/src/gigedit/dimregionchooser.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3132 by schoenebeck, Thu Apr 27 17:31:50 2017 UTC revision 3134 by schoenebeck, Fri Apr 28 12:41:12 2017 UTC
# Line 1246  bool DimRegionChooser::onKeyReleased(Gdk Line 1246  bool DimRegionChooser::onKeyReleased(Gdk
1246      // (which is supposed to switch between regions)      // (which is supposed to switch between regions)
1247      if (primaryKeyDown) return false;      if (primaryKeyDown) return false;
1248    
1249        // avoid conflict with Alt+Shift+Left and Alt+Shift+Right accelerators on
1250        // mainwindow
1251        if (shiftKeyDown) return false;
1252    
1253      if (key->keyval == GDK_KEY_Left)      if (key->keyval == GDK_KEY_Left)
1254          select_prev_dimzone();          select_prev_dimzone();
1255      if (key->keyval == GDK_KEY_Right)      if (key->keyval == GDK_KEY_Right)
# Line 1306  bool DimRegionChooser::select_dimregion( Line 1310  bool DimRegionChooser::select_dimregion(
1310      return false; //.selection failed      return false; //.selection failed
1311  }  }
1312    
1313  void DimRegionChooser::select_next_dimzone() {  void DimRegionChooser::select_next_dimzone(bool add) {
1314      select_dimzone_by_dir(+1);      select_dimzone_by_dir(+1, add);
1315  }  }
1316    
1317  void DimRegionChooser::select_prev_dimzone() {  void DimRegionChooser::select_prev_dimzone(bool add) {
1318      select_dimzone_by_dir(-1);      select_dimzone_by_dir(-1, add);
1319  }  }
1320    
1321  void DimRegionChooser::select_dimzone_by_dir(int dir) {  void DimRegionChooser::select_dimzone_by_dir(int dir, bool add) {
1322      if (!region) return;      if (!region) return;
1323      if (!region->Dimensions) return;      if (!region->Dimensions) return;
1324      if (focus_line < 0) focus_line = 0;      if (focus_line < 0) focus_line = 0;
# Line 1349  void DimRegionChooser::select_dimzone_by Line 1353  void DimRegionChooser::select_dimzone_by
1353    
1354      maindimregno = getDimensionRegionIndex(dr);      maindimregno = getDimensionRegionIndex(dr);
1355    
1356      // reset selected dimregion zones      if (!add) {
1357      dimzones.clear();          // reset selected dimregion zones
1358            dimzones.clear();
1359        }
1360      for (DimensionCase::const_iterator it = maindimcase.begin();      for (DimensionCase::const_iterator it = maindimcase.begin();
1361           it != maindimcase.end(); ++it)           it != maindimcase.end(); ++it)
1362      {      {

Legend:
Removed from v.3132  
changed lines
  Added in v.3134

  ViewVC Help
Powered by ViewVC