History

load Address from settings to get back to domain and path

Stephen Birarda committed 12 years ago

Commit 96aacab1 parent f2710516 files · +27 −21Browse files

Showing the changes to interface/src/Application.cpp (1 of 6 files). Show all

Unified · Split

interface/src/Application.cpp+11−2
@@ -1799,16 +1799,25 @@ void Application::init() { · 1798 unmodified lines
1799 1799
1800 Menu::getInstance()->loadSettings();1800 Menu::getInstance()->loadSettings();
1801 _audio.setReceivedAudioStreamSettings(Menu::getInstance()->getReceivedAudioStreamSettings());1801 _audio.setReceivedAudioStreamSettings(Menu::getInstance()->getReceivedAudioStreamSettings());
1802
1803 qDebug() << "Loaded settings";
1804 1802
1805 // when --url in command line, teleport to location1803 // when --url in command line, teleport to location
1806 const QString HIFI_URL_COMMAND_LINE_KEY = "--url";1804 const QString HIFI_URL_COMMAND_LINE_KEY = "--url";
1807 int urlIndex = arguments().indexOf(HIFI_URL_COMMAND_LINE_KEY);1805 int urlIndex = arguments().indexOf(HIFI_URL_COMMAND_LINE_KEY);
1808 if (urlIndex != -1) {1806 if (urlIndex != -1) {
1809 AddressManager::getInstance().handleLookupString(arguments().value(urlIndex + 1));1807 AddressManager::getInstance().handleLookupString(arguments().value(urlIndex + 1));
1808 } else {
1809 // check if we have a URL in settings to load to jump back to
1810 // we load this separate from the other settings so we don't double lookup a URL
1811 QSettings* interfaceSettings = lockSettings();
1812 QUrl addressURL = interfaceSettings->value(SETTINGS_ADDRESS_KEY).toUrl();
1813
1814 AddressManager::getInstance().handleLookupString(addressURL.toString());
1815
1816 unlockSettings();
1810 }1817 }
1811 1818
1819 qDebug() << "Loaded settings";
1820
1812#ifdef __APPLE__1821#ifdef __APPLE__
1813 if (Menu::getInstance()->isOptionChecked(MenuOption::SixenseEnabled)) {1822 if (Menu::getInstance()->isOptionChecked(MenuOption::SixenseEnabled)) {
1814 // on OS X we only setup sixense if the user wants it on - this allows running without the hid_init crash1823 // on OS X we only setup sixense if the user wants it on - this allows running without the hid_init crash

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t