mirror of https://github.com/procxx/kepka.git
				
				
				
			Core::UpdateApplication using new settings.
This commit is contained in:
		
							parent
							
								
									c1ae9e9680
								
							
						
					
					
						commit
						7d8ba66211
					
				| 
						 | 
					@ -16,7 +16,10 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
 | 
				
			||||||
#include "mtproto/session.h"
 | 
					#include "mtproto/session.h"
 | 
				
			||||||
#include "mainwindow.h"
 | 
					#include "mainwindow.h"
 | 
				
			||||||
#include "core/click_handler_types.h"
 | 
					#include "core/click_handler_types.h"
 | 
				
			||||||
#include "old_settings/settings_widget.h"
 | 
					#include "info/info_memento.h"
 | 
				
			||||||
 | 
					#include "info/settings/info_settings_widget.h"
 | 
				
			||||||
 | 
					#include "window/window_controller.h"
 | 
				
			||||||
 | 
					#include "settings/settings_intro.h"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
extern "C" {
 | 
					extern "C" {
 | 
				
			||||||
#include <openssl/rsa.h>
 | 
					#include <openssl/rsa.h>
 | 
				
			||||||
| 
						 | 
					@ -2124,18 +2127,22 @@ void UpdateApplication() {
 | 
				
			||||||
		}();
 | 
							}();
 | 
				
			||||||
		UrlClickHandler::Open(url);
 | 
							UrlClickHandler::Open(url);
 | 
				
			||||||
	} else {
 | 
						} else {
 | 
				
			||||||
		cSetLastUpdateCheck(0);
 | 
					 | 
				
			||||||
		Core::UpdateChecker().start();
 | 
					 | 
				
			||||||
		if (const auto window = App::wnd()) {
 | 
							if (const auto window = App::wnd()) {
 | 
				
			||||||
			// #TODO settings
 | 
								if (const auto controller = window->controller()) {
 | 
				
			||||||
			auto settings = Box<OldSettings::Widget>();
 | 
									controller->showSection(
 | 
				
			||||||
			const auto weak = make_weak(settings.data());
 | 
										Info::Memento(
 | 
				
			||||||
			window->showSpecialLayer(std::move(settings), anim::type::normal);
 | 
											Info::Settings::Tag{ Auth().user() },
 | 
				
			||||||
			if (weak) {
 | 
											Info::Section::SettingsType::General),
 | 
				
			||||||
				weak->scrollToUpdateRow();
 | 
										Window::SectionShow());
 | 
				
			||||||
 | 
								} else {
 | 
				
			||||||
 | 
									window->showSpecialLayer(
 | 
				
			||||||
 | 
										Box<Settings::LayerWidget>(),
 | 
				
			||||||
 | 
										anim::type::normal);
 | 
				
			||||||
			}
 | 
								}
 | 
				
			||||||
			window->showFromTray();
 | 
								window->showFromTray();
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
 | 
							cSetLastUpdateCheck(0);
 | 
				
			||||||
 | 
							Core::UpdateChecker().start();
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue