Переглянути джерело

Prompt when closing new batch window after indicating intent to associate roasting data.

Neal Wilson 11 роки тому
джерело
коміт
0bca9bf73c
1 змінених файлів з 3 додано та 7 видалено
  1. 3
    7
      config/Windows/newbatch.xml

+ 3
- 7
config/Windows/newbatch.xml Переглянути файл

@@ -180,6 +180,7 @@
180 180
                 }
181 181
             });
182 182
 			profilebutton.clicked.connect(function() {
183
+				batch.windowModified = true;
183 184
 				currentBatchInfo = batch;
184 185
 				query = new QSqlQuery();
185 186
                 var q = "SELECT files FROM item_files WHERE item = :item AND time = (SELECT max(time) FROM item_files WHERE item = :again)";
@@ -240,6 +241,7 @@
240 241
 			});
241 242
 			var noprofilebutton = findChildObject(this, 'noprofile');
242 243
 			noprofilebutton.clicked.connect(function() {
244
+				batch.windowModified = true;
243 245
 				currentBatchInfo = batch;
244 246
 				navigationwindow.loggingWindow.raise();
245 247
 				navigationwindow.loggingWindow.activateWindow();
@@ -247,13 +249,6 @@
247 249
 			var submitbutton = findChildObject(this, 'submit');
248 250
 			var timefield = findChildObject(this, 'time');
249 251
 			var notes = findChildObject(this, 'annotation');
250
-			/*
251
-			var machine = findChildObject(this, 'machine');
252
-            machine.currentIndex = QSettings.value("batchmachine_last", 0);
253
-            machine['currentIndexChanged(int)'].connect(function() {
254
-                QSettings.setValue("batchmachine_last", machine.currentIndex);
255
-            });
256
-			*/
257 252
 			var duration = findChildObject(this, 'duration');
258 253
 			var approval = findChildObject(this, 'approval');
259 254
 			var target = findChildObject(this, 'target');
@@ -315,6 +310,7 @@
315 310
 					query.exec();
316 311
 				}
317 312
                 query = query.invalidate();
313
+				batch.windowModified = false;
318 314
 				batch.close();
319 315
 			});
320 316
         ]]>

Завантаження…
Відмінити
Зберегти