Skip to content

Commit

Permalink
vkconfig3: Prepare Alpha build for internal testing
Browse files Browse the repository at this point in the history
  • Loading branch information
christophe-lunarg committed Oct 3, 2024
1 parent 6ef539f commit 48f86eb
Show file tree
Hide file tree
Showing 17 changed files with 514 additions and 370 deletions.
2 changes: 1 addition & 1 deletion vkconfig_core/environment.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,12 @@ class Environment : public Serialize {

bool has_crashed = false;
int hide_message_boxes_flags = 0;
TabType active_tab = TAB_CONFIGURATIONS;

private:
Environment(const Environment&) = delete;
Environment& operator=(const Environment&) = delete;

TabType active_tab = TAB_DIAGNOSTIC;
LogFlags loader_message_types_flags;
Path home_sdk_path;
};
4 changes: 2 additions & 2 deletions vkconfig_core/test/test_ui.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,11 @@ TEST(test_ui, ExtractLayerName_found) {
TEST(test_ui, GetMainWindowTitle) {
std::string title = GetMainWindowTitle(false, false);

EXPECT_STREQ(("Vulkan Configurator " + Version::VKCONFIG.str()).c_str(), title.c_str());
EXPECT_STREQ(("Vulkan Configurator " + Version::VKCONFIG.str() + "-Alpha").c_str(), title.c_str());
}

TEST(test_ui, GetMainWindowTitle_active) {
std::string title = GetMainWindowTitle(true, false);

EXPECT_STREQ(("Vulkan Configurator " + Version::VKCONFIG.str() + " <ACTIVE>").c_str(), title.c_str());
EXPECT_STREQ(("Vulkan Configurator " + Version::VKCONFIG.str() + "-Alpha <ACTIVE>").c_str(), title.c_str());
}
3 changes: 2 additions & 1 deletion vkconfig_core/type_tab.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ const char* GetToken(TabType type) {
"LAYERS", // TAB_LAYERS
"APPLICATIONS", // TAB_APPLICATIONS
"PREFERENCES", // TAB_PREFERENCES
"HELP" // TAB_HELP
"DOCUMENTATION", // TAB_DOCUMENTATION
"ABOUT" // TAB_ABOUT
};

static_assert(std::size(TOKENS) == TAB_COUNT, "The tranlation table size doesn't match the enum number of elements");
Expand Down
5 changes: 3 additions & 2 deletions vkconfig_core/type_tab.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,11 @@ enum TabType {
TAB_LAYERS,
TAB_APPLICATIONS,
TAB_PREFERENCES,
TAB_HELP,
TAB_DOCUMENTATION,
TAB_ABOUT,

TAB_FIRST = TAB_DIAGNOSTIC,
TAB_LAST = TAB_HELP
TAB_LAST = TAB_ABOUT
};

enum { TAB_COUNT = TAB_LAST - TAB_FIRST + 1 };
Expand Down
2 changes: 1 addition & 1 deletion vkconfig_core/ui.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ std::string ExtractLayerName(const LayerManager& layer_manager, const std::strin
}

std::string GetMainWindowTitle(bool active, bool display_date) {
std::string title = format("%s %s", VKCONFIG_NAME, Version::VKCONFIG.str().c_str());
std::string title = format("%s %s-Alpha", VKCONFIG_NAME, Version::VKCONFIG.str().c_str());

#if VKCONFIG_DATE
if (display_date) {
Expand Down
15 changes: 10 additions & 5 deletions vkconfig_gui/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,16 @@

# Release notes

<<<<<<< HEAD:vkconfig/CHANGELOG.md
## [Vulkan Configurator 2.6.2](https://github.com/LunarG/VulkanTools/tree/main) - October 2024
## [Vulkan Configurator 3.0.0](https://github.com/LunarG/VulkanTools/tree/main) - January 2025

### Features:
- UI redesign: per use case tabs
- Enable loading multiple versions of the same layer
- Enable ordering all layers executed by Vulkan application
- Enable ordering layers independently from enabling them
- Enable storing multiple set applications options for the application launcher

## [Vulkan Configurator 2.6.2](https://github.com/LunarG/VulkanTools/tree/vulkan-sdk-1.3.296.0) - October 2024

### Improvements:
- Show message warnings when overriding implicit layer, either disabling or enabling
Expand All @@ -24,9 +32,6 @@
- Fix renaming configuration with the same name but different cases

## [Vulkan Configurator 2.6.1](https://github.com/LunarG/VulkanTools/tree/vulkan-sdk-1.3.290.0) - July 2024
=======
## [Vulkan Configurator 3.0.0](https://github.com/LunarG/VulkanTools/tree/main) - ??? 2024
>>>>>>> a680297a5... vkconfig3: UI for new Vulkan Loader settings:vkconfig_gui/CHANGELOG.md

### Features:
- Redesign main window UI around tabs
Expand Down
1 change: 0 additions & 1 deletion vkconfig_gui/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@

#include "mainwindow.h"

#include "../vkconfig_core/vulkan_util.h"
#include "../vkconfig_core/vulkan_util.h"
#include "../vkconfig_core/alert.h"
#include "../vkconfig_core/application_singleton.h"
Expand Down
12 changes: 10 additions & 2 deletions vkconfig_gui/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,8 @@ MainWindow::MainWindow(QWidget *parent)
this->tabs[TAB_LAYERS].reset(new TabLayers(*this, ui));
this->tabs[TAB_CONFIGURATIONS].reset(new TabConfigurations(*this, ui));
this->tabs[TAB_PREFERENCES].reset(new TabPreferences(*this, ui));
this->tabs[TAB_HELP].reset(new TabHelp(*this, ui));
this->tabs[TAB_DOCUMENTATION].reset(new TabDocumentation(*this, ui));
this->tabs[TAB_ABOUT].reset(new TabAbout(*this, ui));

connect(ui->action_find_more_layers, SIGNAL(triggered(bool)), this, SLOT(OnHelpFindLayers(bool)));
connect(ui->actionAbout, SIGNAL(triggered(bool)), this, SLOT(OnHelpAbout(bool)));
Expand Down Expand Up @@ -96,7 +97,10 @@ MainWindow::MainWindow(QWidget *parent)
this->restoreGeometry(settings.value("mainwindow/geometry").toByteArray());
this->restoreState(settings.value("mainwindow/state").toByteArray());

this->tabs[this->ui->tab_widget->currentIndex()]->UpdateUI(UPDATE_REBUILD_UI);
const Configurator &configurator = Configurator::Get();

this->ui->tab_widget->setCurrentIndex(configurator.environment.active_tab);
this->tabs[configurator.environment.active_tab]->UpdateUI(UPDATE_REBUILD_UI);

this->UpdateUI_Status();
this->UpdateUI();
Expand Down Expand Up @@ -444,5 +448,9 @@ bool MainWindow::eventFilter(QObject *target, QEvent *event) {

void MainWindow::on_tab_widget_currentChanged(int index) {
assert(index >= 0);

Configurator &configurator = Configurator::Get();
configurator.environment.active_tab = static_cast<TabType>(index);

this->tabs[index]->UpdateUI(UPDATE_REBUILD_UI);
}
4 changes: 2 additions & 2 deletions vkconfig_gui/mainwindow.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@
#include "tab_applications.h"
#include "tab_configurations.h"
#include "tab_diagnostics.h"
#include "tab_help.h"
#include "tab_documentation.h"
#include "tab_layers.h"
#include "tab_preferences.h"

#include "tab_about.h"
#include "ui_mainwindow.h"

#include <QMainWindow>
Expand Down
Loading

0 comments on commit 48f86eb

Please sign in to comment.