mirror of
				https://github.com/arsenetar/dupeguru-cocoa.git
				synced 2025-09-11 17:58:17 +00:00 
			
		
		
		
	Fix issue with picture mode
- Fix issue with multiprocessing launching new UI instances - Picture mode would not work as a result of this - Roll target back to macos 10.12
This commit is contained in:
		
							parent
							
								
									53532e047b
								
							
						
					
					
						commit
						057dc3a451
					
				
							
								
								
									
										14
									
								
								cocoa/main.m
									
									
									
									
									
								
							
							
						
						
									
										14
									
								
								cocoa/main.m
									
									
									
									
									
								
							| @ -24,9 +24,17 @@ int main(int argc, char *argv[]) | ||||
|     Py_SetPythonHome(wPythonPath); | ||||
|     Py_Initialize(); | ||||
|     PyGILState_STATE gilState = PyGILState_Ensure(); | ||||
|     FILE* fp = fopen([mainpy UTF8String], "r"); | ||||
|     PyRun_SimpleFile(fp, [mainpy UTF8String]); | ||||
|     fclose(fp); | ||||
|     /* This main gets called when multiprocessing spawns new threads.  To | ||||
|        prevent this from opening more windows and not working correctly we | ||||
|        are just checking main here and not running the file.  Should be able | ||||
|        to block on the python side of things but checking | ||||
|        __name__ == "__main__" did not seem to work in the one location I tried. | ||||
|      */ | ||||
|     if ([NSThread isMainThread]) { | ||||
|         FILE* fp = fopen([mainpy UTF8String], "r"); | ||||
|         PyRun_SimpleFile(fp, [mainpy UTF8String]); | ||||
|         fclose(fp); | ||||
|     } | ||||
|     PyGILState_Release(gilState); | ||||
|     if (gilState == PyGILState_LOCKED) { | ||||
|         PyThreadState_Swap(NULL); | ||||
|  | ||||
| @ -1348,7 +1348,7 @@ | ||||
| 				GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | ||||
| 				GCC_WARN_UNUSED_FUNCTION = YES; | ||||
| 				GCC_WARN_UNUSED_VARIABLE = YES; | ||||
| 				MACOSX_DEPLOYMENT_TARGET = 11.1; | ||||
| 				MACOSX_DEPLOYMENT_TARGET = 10.12; | ||||
| 				MTL_ENABLE_DEBUG_INFO = YES; | ||||
| 				ONLY_ACTIVE_ARCH = YES; | ||||
| 				SDKROOT = macosx; | ||||
| @ -1399,7 +1399,7 @@ | ||||
| 				GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | ||||
| 				GCC_WARN_UNUSED_FUNCTION = YES; | ||||
| 				GCC_WARN_UNUSED_VARIABLE = YES; | ||||
| 				MACOSX_DEPLOYMENT_TARGET = 11.1; | ||||
| 				MACOSX_DEPLOYMENT_TARGET = 10.12; | ||||
| 				MTL_ENABLE_DEBUG_INFO = NO; | ||||
| 				SDKROOT = macosx; | ||||
| 			}; | ||||
| @ -1418,7 +1418,7 @@ | ||||
| 					"$(inherited)", | ||||
| 					"$(PROJECT_DIR)/build", | ||||
| 				); | ||||
| 				MACOSX_DEPLOYMENT_TARGET = 11.1; | ||||
| 				MACOSX_DEPLOYMENT_TARGET = 10.12; | ||||
| 				PRODUCT_BUNDLE_IDENTIFIER = "com.hardcoded-software.dupeguru"; | ||||
| 				PRODUCT_NAME = dupeGuru; | ||||
| 			}; | ||||
| @ -1437,7 +1437,7 @@ | ||||
| 					"$(inherited)", | ||||
| 					"$(PROJECT_DIR)/build", | ||||
| 				); | ||||
| 				MACOSX_DEPLOYMENT_TARGET = 11.1; | ||||
| 				MACOSX_DEPLOYMENT_TARGET = 10.12; | ||||
| 				PRODUCT_BUNDLE_IDENTIFIER = "com.hardcoded-software.dupeguru"; | ||||
| 				PRODUCT_NAME = dupeGuru; | ||||
| 			}; | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user