Merge pull request #85 from Daverball/save-button-config
Button config menu should save config to disk whenever changes are accepted.
This commit is contained in:
		
						commit
						150abff1c0
					
				
					 2 changed files with 3 additions and 5 deletions
				
			
		| 
						 | 
					@ -321,11 +321,6 @@ int main(int argc, char *argv[])
 | 
				
			||||||
	/* Clean up any remainin events */
 | 
						/* Clean up any remainin events */
 | 
				
			||||||
	eventThread.cleanup();
 | 
						eventThread.cleanup();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	/* Store key bindings */
 | 
					 | 
				
			||||||
	BDescVec keyBinds;
 | 
					 | 
				
			||||||
	rtData.bindingUpdateMsg.get(keyBinds);
 | 
					 | 
				
			||||||
	storeBindings(keyBinds, rtData.config);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
	Debug() << "Shutting down.";
 | 
						Debug() << "Shutting down.";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	SDL_DestroyWindow(win);
 | 
						SDL_DestroyWindow(win);
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -678,6 +678,9 @@ struct SettingsMenuPrivate
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		rtData.bindingUpdateMsg.post(binds);
 | 
							rtData.bindingUpdateMsg.post(binds);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							/* Store the key bindings to disk as well to prevent config loss */
 | 
				
			||||||
 | 
							storeBindings(binds, rtData.config);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		destroyReq = true;
 | 
							destroyReq = true;
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue