mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Add button_url[] and hypertext element to allow mods to open web pages (#13825)
Fixes #12500
This commit is contained in:
parent
6c4a110679
commit
24cc33e704
17 changed files with 530 additions and 37 deletions
|
@ -50,6 +50,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
#include "gui/guiFormSpecMenu.h"
|
||||
#include "gui/guiKeyChangeMenu.h"
|
||||
#include "gui/guiPasswordChange.h"
|
||||
#include "gui/guiOpenURL.h"
|
||||
#include "gui/guiVolumeChange.h"
|
||||
#include "gui/mainmenumanager.h"
|
||||
#include "gui/profilergraph.h"
|
||||
|
@ -1815,6 +1816,12 @@ inline bool Game::handleCallbacks()
|
|||
g_gamecallback->keyconfig_requested = false;
|
||||
}
|
||||
|
||||
if (!g_gamecallback->show_open_url_dialog.empty()) {
|
||||
(new GUIOpenURLMenu(guienv, guiroot, -1,
|
||||
&g_menumgr, texture_src, g_gamecallback->show_open_url_dialog))->drop();
|
||||
g_gamecallback->show_open_url_dialog.clear();
|
||||
}
|
||||
|
||||
if (g_gamecallback->keyconfig_changed) {
|
||||
input->keycache.populate(); // update the cache with new settings
|
||||
g_gamecallback->keyconfig_changed = false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue