mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Touch UI support for desktop builds (#10729)
This commit is contained in:
parent
9f85862b7c
commit
3dcf9e963e
16 changed files with 89 additions and 51 deletions
|
@ -25,6 +25,10 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|||
#include <IGUIStaticText.h>
|
||||
#include <IGUIFont.h>
|
||||
|
||||
#ifdef HAVE_TOUCHSCREENGUI
|
||||
#include "client/renderingengine.h"
|
||||
#endif
|
||||
|
||||
#include "porting.h"
|
||||
#include "gettext.h"
|
||||
|
||||
|
@ -79,8 +83,8 @@ void GUIPasswordChange::regenerateGui(v2u32 screensize)
|
|||
/*
|
||||
Calculate new sizes and positions
|
||||
*/
|
||||
#ifdef __ANDROID__
|
||||
const float s = m_gui_scale * porting::getDisplayDensity() / 2;
|
||||
#ifdef HAVE_TOUCHSCREENGUI
|
||||
const float s = m_gui_scale * RenderingEngine::getDisplayDensity() / 2;
|
||||
#else
|
||||
const float s = m_gui_scale;
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue