GameSentenceMiner 2.8.4__py3-none-any.whl → 2.8.6__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -222,9 +222,6 @@ class WindowsWindowTracker(threading.Thread):
222
222
  if self.window_active != is_active:
223
223
  on_window_activated(is_active)
224
224
  self.window_active = is_active
225
- elif ignore_window_visiblity:
226
- on_window_minimized(False)
227
- self.window_minimized = False
228
225
  else:
229
226
  is_minimized = win32gui.IsIconic(self.window_handle)
230
227
  if self.window_minimized != is_minimized:
@@ -646,16 +643,16 @@ def run(read_from=None,
646
643
  :param screen_capture_combo: When reading with screen capture, specifies a combo to wait on for taking a screenshot instead of using the delay. As an example: "<ctrl>+<shift>+s". The list of keys can be found here: https://pynput.readthedocs.io/en/latest/keyboard.html#pynput.keyboard.Key
647
644
  """
648
645
 
649
- if not read_from:
646
+ if read_from is None:
650
647
  read_from = config.get_general('read_from')
651
648
 
652
- if not screen_capture_area:
649
+ if screen_capture_area is None:
653
650
  screen_capture_area = config.get_general('screen_capture_area')
654
651
 
655
- if not screen_capture_only_active_windows:
652
+ if screen_capture_only_active_windows is None:
656
653
  screen_capture_only_active_windows = config.get_general('screen_capture_only_active_windows')
657
654
 
658
- if not write_to:
655
+ if write_to is None:
659
656
  write_to = config.get_general('write_to')
660
657
 
661
658
  logger.configure(handlers=[{'sink': sys.stderr, 'format': config.get_general('logger_format')}])
@@ -669,8 +666,6 @@ def run(read_from=None,
669
666
 
670
667
  global engine_instances
671
668
  global engine_keys
672
- global ignore_window_visiblity
673
- ignore_window_visiblity = ignore_window_visible
674
669
  engine_instances = []
675
670
  config_engines = []
676
671
  engine_keys = []
@@ -66,9 +66,7 @@
66
66
 
67
67
  async function saveData() {
68
68
  try {
69
- console.log(data)
70
69
  data.args.replacements = textData;
71
- console.log(data)
72
70
  const response = await fetch('/save-data', {
73
71
  method: 'POST',
74
72
  headers: { 'Content-Type': 'application/json' },
@@ -165,33 +163,35 @@
165
163
  const key = keyInput.value.trim();
166
164
  const value = valueInput.value.trim() || "";
167
165
  const originalKey = originalKeyInput.value;
168
- let keyEdited = false;
169
166
 
170
167
  if (!key) {
171
- alert('Key cannot be empty.');
168
+ // Basic validation
169
+ alert('Key and Value cannot be empty.');
172
170
  return;
173
171
  }
174
172
 
173
+ let keyEdited = false;
175
174
  if (originalKey && originalKey !== key) {
176
175
  delete textData[originalKey];
177
176
  keyEdited = true;
178
177
  }
179
178
 
180
179
  if (originalKey) {
181
- textData = { ...textData, [key]: value };
182
180
  if (keyEdited) {
183
- // No need to re-add, it was just updated
181
+ textData = { [key]: value, ...textData };
182
+ } else {
183
+ textData[key] = value;
184
184
  }
185
185
  } else {
186
186
  if (textData.hasOwnProperty(key)) {
187
187
  alert(`Key "${key}" already exists. Please use the Edit function to modify it.`);
188
188
  return;
189
189
  }
190
- textData = { ...textData, [key]: value };
190
+ textData = { [key]: value, ...textData };
191
191
  }
192
192
 
193
193
  await saveData();
194
- await loadData();
194
+ renderTable();
195
195
  modal.style.display = 'none';
196
196
  });
197
197
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: GameSentenceMiner
3
- Version: 2.8.4
3
+ Version: 2.8.6
4
4
  Summary: A tool for mining sentences from games. Update: Multi-Line Mining! Fixed!
5
5
  Author-email: Beangate <bpwhelan95@gmail.com>
6
6
  License: MIT License
@@ -31,7 +31,7 @@ GameSentenceMiner/owocr/owocr/__main__.py,sha256=r8MI6RAmbkTWqOJ59uvXoDS7CSw5jX5
31
31
  GameSentenceMiner/owocr/owocr/config.py,sha256=738QCJHEWpFhMh966plOcXYWwcshSiRsxjjIwldeTtI,7461
32
32
  GameSentenceMiner/owocr/owocr/lens_betterproto.py,sha256=oNoISsPilVVRBBPVDtb4-roJtAhp8ZAuFTci3TGXtMc,39141
33
33
  GameSentenceMiner/owocr/owocr/ocr.py,sha256=n24Xg8Z8dbcgLpq1u4d22z3tLV1evmf0dK3-Xocv3vs,39878
34
- GameSentenceMiner/owocr/owocr/run.py,sha256=rYITJJXKEaR7tW_M7KQ29Zh5zOFH4GcIy-p9PEqbRRE,48066
34
+ GameSentenceMiner/owocr/owocr/run.py,sha256=WP3YTocRnZh4AHysIgLokemcaowatMjwfxS0IcxIHps,47859
35
35
  GameSentenceMiner/owocr/owocr/screen_coordinate_picker.py,sha256=fjJ3CSXLti3WboGPpmsa7MWOwIXsfpHC8N4zKahGGY0,3346
36
36
  GameSentenceMiner/vad/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
37
37
  GameSentenceMiner/vad/silero_trim.py,sha256=ULf3zwS-JMsY82cKF7gZxREHw8L6lgpWF2U1YqgE9Oc,1681
@@ -46,13 +46,13 @@ GameSentenceMiner/web/static/favicon.ico,sha256=7d25r_FBqRSNsAoEHpSzNoT7zyVt2DJR
46
46
  GameSentenceMiner/web/static/favicon.svg,sha256=x305AP6WlXGtrXIZlaQspdLmwteoFYUoe5FyJ9MYlJ8,11517
47
47
  GameSentenceMiner/web/static/site.webmanifest,sha256=kaeNT-FjFt-T7JGzOhXH7YSqsrDeiplZ2kDxCN_CFU4,436
48
48
  GameSentenceMiner/web/static/style.css,sha256=bPZK0NVMuyRl5NNDuT7ZTzVLKlvSsdmeVHmAW4y5FM0,7001
49
- GameSentenceMiner/web/static/text_replacements.html,sha256=LJ2qBEZvyMaBJLLJzDIw0baiTeusplbn4jkpyHM6ZBI,8613
49
+ GameSentenceMiner/web/static/text_replacements.html,sha256=tV5c8mCaWSt_vKuUpbdbLAzXZ3ATZeDvQ9PnnAfqY0M,8598
50
50
  GameSentenceMiner/web/static/utility.html,sha256=58br1whazdfrevWCHEzYNa1_VdBvebDDX2tWlX2QrFs,9964
51
51
  GameSentenceMiner/web/static/web-app-manifest-192x192.png,sha256=EfSNnBmsSaLfESbkGfYwbKzcjKOdzuWo18ABADfN974,51117
52
52
  GameSentenceMiner/web/static/web-app-manifest-512x512.png,sha256=wyqgCWCrLEUxSRXmaA3iJEESd-vM-ZmlTtZFBY4V8Pk,230819
53
- gamesentenceminer-2.8.4.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
54
- gamesentenceminer-2.8.4.dist-info/METADATA,sha256=S3MxkE5od51DTveOhaPwiBa5tGA3UV1jqTGjpUnGXJs,5912
55
- gamesentenceminer-2.8.4.dist-info/WHEEL,sha256=SmOxYU7pzNKBqASvQJ7DjX3XGUF92lrGhMb3R6_iiqI,91
56
- gamesentenceminer-2.8.4.dist-info/entry_points.txt,sha256=2APEP25DbfjSxGeHtwBstMH8mulVhLkqF_b9bqzU6vQ,65
57
- gamesentenceminer-2.8.4.dist-info/top_level.txt,sha256=V1hUY6xVSyUEohb0uDoN4UIE6rUZ_JYx8yMyPGX4PgQ,18
58
- gamesentenceminer-2.8.4.dist-info/RECORD,,
53
+ gamesentenceminer-2.8.6.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
54
+ gamesentenceminer-2.8.6.dist-info/METADATA,sha256=-y0KqwQGu8y7OVhrpmzL0JSPusDvd4YtcxSip82DND4,5912
55
+ gamesentenceminer-2.8.6.dist-info/WHEEL,sha256=SmOxYU7pzNKBqASvQJ7DjX3XGUF92lrGhMb3R6_iiqI,91
56
+ gamesentenceminer-2.8.6.dist-info/entry_points.txt,sha256=2APEP25DbfjSxGeHtwBstMH8mulVhLkqF_b9bqzU6vQ,65
57
+ gamesentenceminer-2.8.6.dist-info/top_level.txt,sha256=V1hUY6xVSyUEohb0uDoN4UIE6rUZ_JYx8yMyPGX4PgQ,18
58
+ gamesentenceminer-2.8.6.dist-info/RECORD,,