+ return m_impl->GetGeometry();
+}
+
+wxRect wxDisplay::GetClientArea() const
+{
+ wxCHECK_MSG( IsOk(), wxRect(), _T("invalid wxDisplay object") );
+
+ return m_impl->GetClientArea();
+}
+
+wxString wxDisplay::GetName() const
+{
+ wxCHECK_MSG( IsOk(), wxString(), _T("invalid wxDisplay object") );
+
+ return m_impl->GetName();
+}
+
+bool wxDisplay::IsPrimary() const
+{
+ return m_impl && m_impl->GetIndex() == 0;
+}
+
+#if wxUSE_DISPLAY
+
+wxArrayVideoModes wxDisplay::GetModes(const wxVideoMode& mode) const
+{
+ wxCHECK_MSG( IsOk(), wxArrayVideoModes(), _T("invalid wxDisplay object") );
+
+ return m_impl->GetModes(mode);
+}
+
+wxVideoMode wxDisplay::GetCurrentMode() const
+{
+ wxCHECK_MSG( IsOk(), wxVideoMode(), _T("invalid wxDisplay object") );
+
+ return m_impl->GetCurrentMode();
+}
+
+bool wxDisplay::ChangeMode(const wxVideoMode& mode)
+{
+ wxCHECK_MSG( IsOk(), false, _T("invalid wxDisplay object") );
+
+ return m_impl->ChangeMode(mode);
+}
+
+#endif // wxUSE_DIRECTDRAW
+
+// ----------------------------------------------------------------------------
+// static functions implementation
+// ----------------------------------------------------------------------------
+
+// if wxUSE_DISPLAY == 1 this is implemented in port-specific code
+#if !wxUSE_DISPLAY
+
+/* static */ wxDisplayFactory *wxDisplay::CreateFactory()
+{
+ return new wxDisplayFactorySingle;
+}
+
+#endif // !wxUSE_DISPLAY
+
+/* static */ wxDisplayFactory& wxDisplay::Factory()
+{
+ if ( !gs_factory )
+ {
+ gs_factory = CreateFactory();
+ }
+
+ return *gs_factory;
+}
+
+// ============================================================================
+// wxDisplayFactory implementation
+// ============================================================================
+
+int wxDisplayFactory::GetFromWindow(wxWindow *window)
+{
+ // consider that the window belongs to the display containing its centre