Skip to content

Commit

Permalink
Split display to its own file
Browse files Browse the repository at this point in the history
  • Loading branch information
kunitoki committed May 2, 2024
1 parent a8390fb commit 7419644
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 14 deletions.
14 changes: 0 additions & 14 deletions modules/yup_gui/desktop/yup_Desktop.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,20 +22,6 @@
namespace juce
{

class JUCE_API Display
{
public:
Display() {}

Size<int> physicalSizeMillimeters;
float contentScaleX = 1.0f;
float contentScaleY = 1.0f;
Point<int> virtualPosition;
Rectangle<int> workArea;
String name;
bool isPrimary = false;
};

class JUCE_API Desktop
{
public:
Expand Down
39 changes: 39 additions & 0 deletions modules/yup_gui/desktop/yup_Display.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
/*
==============================================================================
This file is part of the YUP library.
Copyright (c) 2024 - kunitoki@gmail.com
YUP is an open source library subject to open-source licensing.
The code included in this file is provided under the terms of the ISC license
http://www.isc.org/downloads/software-support-policy/isc-license. Permission
to use, copy, modify, and/or distribute this software for any purpose with or
without fee is hereby granted provided that the above copyright notice and
this permission notice appear in all copies.
YUP IS PROVIDED "AS IS" WITHOUT ANY WARRANTY, AND ALL WARRANTIES, WHETHER
EXPRESSED OR IMPLIED, INCLUDING MERCHANTABILITY AND FITNESS FOR PURPOSE, ARE
DISCLAIMED.
==============================================================================
*/

namespace juce
{

class JUCE_API Display
{
public:
Display() {}

Size<int> physicalSizeMillimeters;
float contentScaleX = 1.0f;
float contentScaleY = 1.0f;
Point<int> virtualPosition;
Rectangle<int> workArea;
String name;
bool isPrimary = false;
};

} // namespace juce
1 change: 1 addition & 0 deletions modules/yup_gui/yup_gui.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@
#include "keyboard/yup_KeyModifiers.h"
#include "keyboard/yup_KeyPress.h"
#include "mouse/yup_MouseEvent.h"
#include "desktop/yup_Display.h"
#include "desktop/yup_Desktop.h"
#include "component/yup_ComponentNative.h"
#include "component/yup_Component.h"
Expand Down

0 comments on commit 7419644

Please sign in to comment.