Showing the changes to interface/src/Menu.cpp (1 of 1 file). Show all
Unified · Split
| @@ -745,7 +745,7 @@ QLineEdit* lineEditForDomainHostname() { · 744 unmodified lines | |||
| 745 | 745 | ||
| 746 | void Menu::login() { | 746 | void Menu::login() { |
| 747 | Application* applicationInstance = Application::getInstance(); | 747 | Application* applicationInstance = Application::getInstance(); |
| 748 | QDialog dialog(applicationInstance->getGLWidget()); | 748 | QDialog dialog; |
| 749 | dialog.setWindowTitle("Login"); | 749 | dialog.setWindowTitle("Login"); |
| 750 | QBoxLayout* layout = new QBoxLayout(QBoxLayout::TopToBottom); | 750 | QBoxLayout* layout = new QBoxLayout(QBoxLayout::TopToBottom); |
| 751 | dialog.setLayout(layout); | 751 | dialog.setLayout(layout); |
| @@ -764,7 +764,6 @@ void Menu::login() { · 12 unmodified lines | |||
| 764 | layout->addWidget(buttons); | 764 | layout->addWidget(buttons); |
| 765 | 765 | ||
| 766 | int ret = dialog.exec(); | 766 | int ret = dialog.exec(); |
| 767 | applicationInstance->getWindow()->activateWindow(); | ||
| 768 | if (ret != QDialog::Accepted) { | 767 | if (ret != QDialog::Accepted) { |
| 769 | return; | 768 | return; |
| 770 | } | 769 | } |
| @@ -779,7 +778,7 @@ void Menu::login() { · 8 unmodified lines | |||
| 779 | void Menu::editPreferences() { | 778 | void Menu::editPreferences() { |
| 780 | Application* applicationInstance = Application::getInstance(); | 779 | Application* applicationInstance = Application::getInstance(); |
| 781 | 780 | ||
| 782 | QDialog dialog(applicationInstance->getGLWidget()); | 781 | QDialog dialog; |
| 783 | dialog.setWindowTitle("Interface Preferences"); | 782 | dialog.setWindowTitle("Interface Preferences"); |
| 784 | QBoxLayout* layout = new QBoxLayout(QBoxLayout::TopToBottom); | 783 | QBoxLayout* layout = new QBoxLayout(QBoxLayout::TopToBottom); |
| 785 | dialog.setLayout(layout); | 784 | dialog.setLayout(layout); |
| @@ -837,7 +836,6 @@ void Menu::editPreferences() { · 51 unmodified lines | |||
| 837 | layout->addWidget(buttons); | 836 | layout->addWidget(buttons); |
| 838 | 837 | ||
| 839 | int ret = dialog.exec(); | 838 | int ret = dialog.exec(); |
| 840 | applicationInstance->getWindow()->activateWindow(); | ||
| 841 | if (ret != QDialog::Accepted) { | 839 | if (ret != QDialog::Accepted) { |
| 842 | return; | 840 | return; |
| 843 | } | 841 | } |
| @@ -887,8 +885,7 @@ void Menu::editPreferences() { · 43 unmodified lines | |||
| 887 | } | 885 | } |
| 888 | 886 | ||
| 889 | void Menu::goToDomain() { | 887 | void Menu::goToDomain() { |
| 890 | Application* applicationInstance = Application::getInstance(); | 888 | QDialog dialog; |
| 891 | QDialog dialog(applicationInstance->getGLWidget()); | ||
| 892 | dialog.setWindowTitle("Go To Domain"); | 889 | dialog.setWindowTitle("Go To Domain"); |
| 893 | QBoxLayout* layout = new QBoxLayout(QBoxLayout::TopToBottom); | 890 | QBoxLayout* layout = new QBoxLayout(QBoxLayout::TopToBottom); |
| 894 | dialog.setLayout(layout); | 891 | dialog.setLayout(layout); |
| @@ -906,7 +903,6 @@ void Menu::goToDomain() { · 11 unmodified lines | |||
| 906 | layout->addWidget(buttons); | 903 | layout->addWidget(buttons); |
| 907 | 904 | ||
| 908 | int ret = dialog.exec(); | 905 | int ret = dialog.exec(); |
| 909 | applicationInstance->getWindow()->activateWindow(); | ||
| 910 | if (ret != QDialog::Accepted) { | 906 | if (ret != QDialog::Accepted) { |
| 911 | return; | 907 | return; |
| 912 | } | 908 | } |
| @@ -915,8 +911,7 @@ void Menu::goToDomain() { · 2 unmodified lines | |||
| 915 | } | 911 | } |
| 916 | 912 | ||
| 917 | void Menu::goToLocation() { | 913 | void Menu::goToLocation() { |
| 918 | Application* applicationInstance = Application::getInstance(); | 914 | QDialog dialog; |
| 919 | QDialog dialog(applicationInstance->getGLWidget()); | ||
| 920 | dialog.setWindowTitle("Go To Location"); | 915 | dialog.setWindowTitle("Go To Location"); |
| 921 | QBoxLayout* layout = new QBoxLayout(QBoxLayout::TopToBottom); | 916 | QBoxLayout* layout = new QBoxLayout(QBoxLayout::TopToBottom); |
| 922 | dialog.setLayout(layout); | 917 | dialog.setLayout(layout); |
| @@ -926,8 +921,8 @@ void Menu::goToLocation() { · 3 unmodified lines | |||
| 926 | 921 | ||
| 927 | const int QLINE_MINIMUM_WIDTH = 300; | 922 | const int QLINE_MINIMUM_WIDTH = 300; |
| 928 | 923 | ||
| 929 | Application* appInstance = Application::getInstance(); | 924 | Application* applicationInstance = Application::getInstance(); |
| 930 | MyAvatar* myAvatar = appInstance->getAvatar(); | 925 | MyAvatar* myAvatar = applicationInstance->getAvatar(); |
| 931 | glm::vec3 avatarPos = myAvatar->getPosition(); | 926 | glm::vec3 avatarPos = myAvatar->getPosition(); |
| 932 | QString currentLocation = QString("%1, %2, %3").arg(QString::number(avatarPos.x), | 927 | QString currentLocation = QString("%1, %2, %3").arg(QString::number(avatarPos.x), |
| 933 | QString::number(avatarPos.y), QString::number(avatarPos.z)); | 928 | QString::number(avatarPos.y), QString::number(avatarPos.z)); |
| @@ -942,7 +937,6 @@ void Menu::goToLocation() { · 8 unmodified lines | |||
| 942 | layout->addWidget(buttons); | 937 | layout->addWidget(buttons); |
| 943 | 938 | ||
| 944 | int ret = dialog.exec(); | 939 | int ret = dialog.exec(); |
| 945 | applicationInstance->getWindow()->activateWindow(); | ||
| 946 | if (ret != QDialog::Accepted) { | 940 | if (ret != QDialog::Accepted) { |
| 947 | return; | 941 | return; |
| 948 | } | 942 | } |
| @@ -974,8 +968,7 @@ void Menu::goToLocation() { · 25 unmodified lines | |||
| 974 | } | 968 | } |
| 975 | 969 | ||
| 976 | void Menu::goToUser() { | 970 | void Menu::goToUser() { |
| 977 | Application* applicationInstance = Application::getInstance(); | 971 | QDialog dialog; |
| 978 | QDialog dialog(applicationInstance->getGLWidget()); | ||
| 979 | dialog.setWindowTitle("Go To User"); | 972 | dialog.setWindowTitle("Go To User"); |
| 980 | QBoxLayout* layout = new QBoxLayout(QBoxLayout::TopToBottom); | 973 | QBoxLayout* layout = new QBoxLayout(QBoxLayout::TopToBottom); |
| 981 | dialog.setLayout(layout); | 974 | dialog.setLayout(layout); |
| @@ -993,7 +986,6 @@ void Menu::goToUser() { · 11 unmodified lines | |||
| 993 | layout->addWidget(buttons); | 986 | layout->addWidget(buttons); |
| 994 | 987 | ||
| 995 | int ret = dialog.exec(); | 988 | int ret = dialog.exec(); |
| 996 | applicationInstance->getWindow()->activateWindow(); | ||
| 997 | if (ret != QDialog::Accepted) { | 989 | if (ret != QDialog::Accepted) { |
| 998 | return; | 990 | return; |
| 999 | } | 991 | } |