mirror of
				https://github.com/subsurface/subsurface.git
				synced 2025-02-19 22:16:15 +00:00 
			
		
		
		
	Correctly track the 'changed' status of the equipment widgets
updateDive() cannot reset the changed status - this is called while the dive is edited. Instead this status is reset when the user either accepts or rejects the changes. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
		
							parent
							
								
									327ea3aca4
								
							
						
					
					
						commit
						0cf55d7e39
					
				
					 2 changed files with 4 additions and 2 deletions
				
			
		|  | @ -757,6 +757,8 @@ void MainTab::acceptChanges() | |||
| 	DivePlannerPointsModel::instance()->setPlanMode(DivePlannerPointsModel::NOTHING); | ||||
| 	MainWindow::instance()->dive_list()->verticalScrollBar()->setSliderPosition(scrolledBy); | ||||
| 	MainWindow::instance()->dive_list()->setFocus(); | ||||
| 	cylindersModel->changed = false; | ||||
| 	weightModel->changed = false; | ||||
| } | ||||
| 
 | ||||
| void MainTab::resetPallete() | ||||
|  | @ -818,6 +820,8 @@ void MainTab::rejectChanges() | |||
| 	MainWindow::instance()->globe()->reload(); | ||||
| 	// show the profile and dive info
 | ||||
| 	MainWindow::instance()->graphics()->replot(); | ||||
| 	cylindersModel->changed = false; | ||||
| 	weightModel->changed = false; | ||||
| 	cylindersModel->updateDive(); | ||||
| 	weightModel->updateDive(); | ||||
| } | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue