mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-13 01:29:11 +01:00
822326eea9
From wxWidgets master 81570ae070b35c9d52de47b1f14897f3ff1a66c7. include/wx/defs.h -- __w64 warning disable patch by comex brought forward. include/wx/msw/window.h -- added GetContentScaleFactor() which was not implemented on Windows but is necessary for wxBitmap scaling on Mac OS X so it needs to work to avoid #ifdef-ing the code. src/gtk/window.cpp -- Modified DoSetClientSize() to direct call wxWindowGTK::DoSetSize() instead of using public wxWindowBase::SetSize() which now prevents derived classes (like wxAuiToolbar) intercepting the call and breaking it. This matches Windows which does NOT need to call DoSetSize internally. End result is this fixes Dolphin's debug tools toolbars on Linux. src/osx/window_osx.cpp -- Same fix as for GTK since it has the same issue. src/msw/radiobox.cpp -- Hacked to fix display in HiDPI (was clipping off end of text). Updated CMakeLists for Linux and Mac OS X. Small code changes to Dolphin to fix debug error boxes, deprecation warnings, and retain previous UI behavior on Windows.
91 lines
2.6 KiB
C++
91 lines
2.6 KiB
C++
/////////////////////////////////////////////////////////////////////////////
|
|
// Name: wx/generic/stattextg.h
|
|
// Purpose: wxGenericStaticText header
|
|
// Author: Marcin Wojdyr
|
|
// Created: 2008-06-26
|
|
// Copyright: Marcin Wojdyr
|
|
// Licence: wxWindows licence
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
#ifndef _WX_GENERIC_STATTEXTG_H_
|
|
#define _WX_GENERIC_STATTEXTG_H_
|
|
|
|
// prevent it from including the platform-specific wxStaticText declaration as
|
|
// this is not going to compile if it derives from wxGenericStaticText defined
|
|
// below (currently this is only the case in wxUniv but it could also happen
|
|
// with other ports)
|
|
#define wxNO_PORT_STATTEXT_INCLUDE
|
|
#include "wx/stattext.h"
|
|
#undef wxNO_PORT_STATTEXT_INCLUDE
|
|
|
|
class WXDLLIMPEXP_CORE wxGenericStaticText : public wxStaticTextBase
|
|
{
|
|
public:
|
|
wxGenericStaticText() { Init(); }
|
|
|
|
wxGenericStaticText(wxWindow *parent,
|
|
wxWindowID id,
|
|
const wxString& label,
|
|
const wxPoint& pos = wxDefaultPosition,
|
|
const wxSize& size = wxDefaultSize,
|
|
long style = 0,
|
|
const wxString& name = wxStaticTextNameStr)
|
|
{
|
|
Init();
|
|
|
|
Create(parent, id, label, pos, size, style, name);
|
|
}
|
|
|
|
bool Create(wxWindow *parent,
|
|
wxWindowID id,
|
|
const wxString& label,
|
|
const wxPoint& pos = wxDefaultPosition,
|
|
const wxSize& size = wxDefaultSize,
|
|
long style = 0,
|
|
const wxString& name = wxStaticTextNameStr);
|
|
|
|
virtual ~wxGenericStaticText();
|
|
|
|
|
|
// overridden base class virtual methods
|
|
virtual void SetLabel(const wxString& label) wxOVERRIDE;
|
|
virtual bool SetFont(const wxFont &font) wxOVERRIDE;
|
|
|
|
protected:
|
|
virtual wxSize DoGetBestClientSize() const wxOVERRIDE;
|
|
|
|
virtual wxString DoGetLabel() const wxOVERRIDE { return m_label; }
|
|
virtual void DoSetLabel(const wxString& label) wxOVERRIDE;
|
|
|
|
void DoSetSize(int x, int y, int width, int height, int sizeFlags) wxOVERRIDE;
|
|
|
|
#if wxUSE_MARKUP
|
|
virtual bool DoSetLabelMarkup(const wxString& markup) wxOVERRIDE;
|
|
#endif // wxUSE_MARKUP
|
|
|
|
private:
|
|
void Init()
|
|
{
|
|
#if wxUSE_MARKUP
|
|
m_markupText = NULL;
|
|
#endif // wxUSE_MARKUP
|
|
}
|
|
|
|
void OnPaint(wxPaintEvent& event);
|
|
|
|
void DoDrawLabel(wxDC& dc, const wxRect& rect);
|
|
|
|
// These fields are only used if m_markupText == NULL.
|
|
wxString m_label;
|
|
int m_mnemonic;
|
|
|
|
#if wxUSE_MARKUP
|
|
class wxMarkupText *m_markupText;
|
|
#endif // wxUSE_MARKUP
|
|
|
|
wxDECLARE_DYNAMIC_CLASS_NO_COPY(wxGenericStaticText);
|
|
};
|
|
|
|
#endif // _WX_GENERIC_STATTEXTG_H_
|
|
|