mirror of
https://github.com/ciphervance/supercell-wx.git
synced 2025-10-30 17:00:05 +00:00
Added cursor icon always on option to general settings
This commit is contained in:
parent
40b3ecce16
commit
64b679a002
6 changed files with 43 additions and 9 deletions
|
|
@ -328,9 +328,13 @@ void OverlayLayer::Render(const QMapLibre::CustomLayerRenderParameters& params)
|
|||
p->activeBoxInner_->SetBorder(1.0f * pixelRatio, {255, 255, 255, 255});
|
||||
}
|
||||
|
||||
auto& generalSettings = settings::GeneralSettings::Instance();
|
||||
|
||||
// Cursor Icon
|
||||
bool cursorIconVisible = QGuiApplication::keyboardModifiers() &
|
||||
Qt::KeyboardModifier::ControlModifier;
|
||||
bool cursorIconVisible =
|
||||
generalSettings.cursor_icon_always_on().GetValue() ||
|
||||
(QGuiApplication::keyboardModifiers() &
|
||||
Qt::KeyboardModifier::ControlModifier);
|
||||
p->geoIcons_->SetIconVisible(p->cursorIcon_, cursorIconVisible);
|
||||
if (cursorIconVisible)
|
||||
{
|
||||
|
|
@ -434,8 +438,6 @@ void OverlayLayer::Render(const QMapLibre::CustomLayerRenderParameters& params)
|
|||
ImGui::End();
|
||||
}
|
||||
|
||||
auto& generalSettings = settings::GeneralSettings::Instance();
|
||||
|
||||
// Map Center Icon
|
||||
if (params.width != p->lastWidth_ || params.height != p->lastHeight_)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue