convert impress remote dialog to .ui
Change-Id: I4ed22a776720bd6de64d08767a03a746276acba4
This commit is contained in:
@@ -533,6 +533,10 @@
|
|||||||
generic-name="BmpWindow" parent="GtkDrawingArea"
|
generic-name="BmpWindow" parent="GtkDrawingArea"
|
||||||
icon-name="widget-gtk-drawingarea"/>
|
icon-name="widget-gtk-drawingarea"/>
|
||||||
|
|
||||||
|
<glade-widget-class title="ClientBox" name="sduilo-ClientBox"
|
||||||
|
generic-name="ClientBox" parent="GtkDrawingArea"
|
||||||
|
icon-name="widget-gtk-drawingarea"/>
|
||||||
|
|
||||||
<glade-widget-class title="Recent Documents View" name="sfxlo-RecentDocsView"
|
<glade-widget-class title="Recent Documents View" name="sfxlo-RecentDocsView"
|
||||||
generic-name="Icon View" parent="GtkIconView"
|
generic-name="Icon View" parent="GtkIconView"
|
||||||
icon-name="widget-gtk-iconview"/>
|
icon-name="widget-gtk-iconview"/>
|
||||||
|
@@ -48,7 +48,6 @@ $(eval $(call gb_SrsTarget_add_files,sd/res,\
|
|||||||
sd/source/ui/dlg/LayerDialog.src \
|
sd/source/ui/dlg/LayerDialog.src \
|
||||||
sd/source/ui/dlg/navigatr.src \
|
sd/source/ui/dlg/navigatr.src \
|
||||||
sd/source/ui/dlg/PaneDockingWindow.src \
|
sd/source/ui/dlg/PaneDockingWindow.src \
|
||||||
sd/source/ui/dlg/RemoteDialog.src \
|
|
||||||
sd/source/ui/dlg/sdpreslt.src \
|
sd/source/ui/dlg/sdpreslt.src \
|
||||||
sd/source/ui/dlg/tpaction.src \
|
sd/source/ui/dlg/tpaction.src \
|
||||||
sd/source/ui/dlg/vectdlg.src \
|
sd/source/ui/dlg/vectdlg.src \
|
||||||
|
@@ -89,6 +89,7 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/simpress,\
|
|||||||
sd/uiconfig/simpress/ui/presentationdialog \
|
sd/uiconfig/simpress/ui/presentationdialog \
|
||||||
sd/uiconfig/simpress/ui/printeroptions \
|
sd/uiconfig/simpress/ui/printeroptions \
|
||||||
sd/uiconfig/simpress/ui/prntopts \
|
sd/uiconfig/simpress/ui/prntopts \
|
||||||
|
sd/uiconfig/simpress/ui/remotedialog \
|
||||||
sd/uiconfig/simpress/ui/sdviewpage \
|
sd/uiconfig/simpress/ui/sdviewpage \
|
||||||
sd/uiconfig/simpress/ui/slidetransitionspanel \
|
sd/uiconfig/simpress/ui/slidetransitionspanel \
|
||||||
sd/uiconfig/simpress/ui/tabledesignpanel \
|
sd/uiconfig/simpress/ui/tabledesignpanel \
|
||||||
|
@@ -127,6 +127,7 @@
|
|||||||
#define STR_SLIDE_NAME RID_GLOB_START+112
|
#define STR_SLIDE_NAME RID_GLOB_START+112
|
||||||
#define STR_LEFT_IMPRESS_PANE_SHELL RID_GLOB_START+113
|
#define STR_LEFT_IMPRESS_PANE_SHELL RID_GLOB_START+113
|
||||||
#define STR_LEFT_DRAW_PANE_SHELL RID_GLOB_START+114
|
#define STR_LEFT_DRAW_PANE_SHELL RID_GLOB_START+114
|
||||||
|
#define STR_ENTER_PIN RID_GLOB_START+115
|
||||||
#define STR_TOOL_PANEL_SHELL RID_GLOB_START+116
|
#define STR_TOOL_PANEL_SHELL RID_GLOB_START+116
|
||||||
|
|
||||||
#define STR_TASKPANEVIEWSHELL RID_GLOB_START+117
|
#define STR_TASKPANEVIEWSHELL RID_GLOB_START+117
|
||||||
|
@@ -449,4 +449,9 @@ String STR_POOLSHEET_LAST_COLUMN
|
|||||||
Text [ en-US ] = "Last column" ;
|
Text [ en-US ] = "Last column" ;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
String STR_ENTER_PIN
|
||||||
|
{
|
||||||
|
Text [ en-US ] = "Enter PIN:";
|
||||||
|
};
|
||||||
|
|
||||||
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
||||||
|
@@ -12,19 +12,18 @@
|
|||||||
#include "cusshow.hxx"
|
#include "cusshow.hxx"
|
||||||
|
|
||||||
#include "RemoteDialog.hxx"
|
#include "RemoteDialog.hxx"
|
||||||
#include "RemoteDialog.hrc"
|
|
||||||
#include "RemoteServer.hxx"
|
#include "RemoteServer.hxx"
|
||||||
|
|
||||||
using namespace ::sd;
|
using namespace ::sd;
|
||||||
using namespace ::std;
|
using namespace ::std;
|
||||||
|
|
||||||
RemoteDialog::RemoteDialog( Window *pWindow ) :
|
RemoteDialog::RemoteDialog( Window *pWindow )
|
||||||
ModalDialog( pWindow, SdResId( DLG_PAIR_REMOTE ) ),
|
: ModalDialog(pWindow, "RemoteDialog",
|
||||||
mButtonConnect( this, SdResId( BTN_CONNECT ) ),
|
"modules/simpress/ui/remotedialog.ui")
|
||||||
mButtonCancel( this, SdResId( BTN_CANCEL ) ),
|
|
||||||
mClientBox( this, SdResId( LB_SERVERS ) )
|
|
||||||
{
|
{
|
||||||
FreeResource();
|
get(m_pButtonConnect, "connect");
|
||||||
|
get(m_pButtonClose, "close");
|
||||||
|
get(m_pClientBox, "tree");
|
||||||
|
|
||||||
#ifdef ENABLE_SDREMOTE
|
#ifdef ENABLE_SDREMOTE
|
||||||
RemoteServer::ensureDiscoverable();
|
RemoteServer::ensureDiscoverable();
|
||||||
@@ -36,30 +35,25 @@ RemoteDialog::RemoteDialog( Window *pWindow ) :
|
|||||||
for ( vector<ClientInfo*>::const_iterator aIt( aClients.begin() );
|
for ( vector<ClientInfo*>::const_iterator aIt( aClients.begin() );
|
||||||
aIt != aEnd; ++aIt )
|
aIt != aEnd; ++aIt )
|
||||||
{
|
{
|
||||||
mClientBox.addEntry( *aIt );
|
m_pClientBox->addEntry( *aIt );
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
mButtonConnect.SetClickHdl( LINK( this, RemoteDialog, HandleConnectButton ) );
|
m_pButtonConnect->SetClickHdl( LINK( this, RemoteDialog, HandleConnectButton ) );
|
||||||
SetCloseHdl( LINK( this, RemoteDialog, CloseHdl ) );
|
SetCloseHdl( LINK( this, RemoteDialog, CloseHdl ) );
|
||||||
mButtonCancel.SetClickHdl( LINK( this, RemoteDialog, CloseHdl ) );
|
m_pButtonClose->SetClickHdl( LINK( this, RemoteDialog, CloseHdl ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
RemoteDialog::~RemoteDialog()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
// -----------------------------------------------------------------------
|
|
||||||
IMPL_LINK_NOARG(RemoteDialog, HandleConnectButton)
|
IMPL_LINK_NOARG(RemoteDialog, HandleConnectButton)
|
||||||
{
|
{
|
||||||
// setBusy( true );
|
// setBusy( true );
|
||||||
// Fixme: Try and connect
|
// Fixme: Try and connect
|
||||||
#if defined(ENABLE_SDREMOTE) && defined(ENABLE_SDREMOTE_BLUETOOTH)
|
#if defined(ENABLE_SDREMOTE) && defined(ENABLE_SDREMOTE_BLUETOOTH)
|
||||||
long aSelected = mClientBox.GetActiveEntryIndex();
|
long aSelected = m_pClientBox->GetActiveEntryIndex();
|
||||||
if ( aSelected < 0 )
|
if ( aSelected < 0 )
|
||||||
return 1;
|
return 1;
|
||||||
TClientBoxEntry aEntry = mClientBox.GetEntryData(aSelected);
|
TClientBoxEntry aEntry = m_pClientBox->GetEntryData(aSelected);
|
||||||
OUString aPin ( mClientBox.getPin() );
|
OUString aPin ( m_pClientBox->getPin() );
|
||||||
if ( RemoteServer::connectClient( aEntry->m_pClientInfo, aPin ) )
|
if ( RemoteServer::connectClient( aEntry->m_pClientInfo, aPin ) )
|
||||||
{
|
{
|
||||||
return CloseHdl( 0 );
|
return CloseHdl( 0 );
|
||||||
|
@@ -24,16 +24,14 @@ namespace sd
|
|||||||
class RemoteDialog : public ModalDialog
|
class RemoteDialog : public ModalDialog
|
||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
OKButton mButtonConnect;
|
PushButton* m_pButtonConnect;
|
||||||
CancelButton mButtonCancel;
|
CloseButton* m_pButtonClose;
|
||||||
ClientBox mClientBox;
|
ClientBox* m_pClientBox;
|
||||||
|
|
||||||
DECL_DLLPRIVATE_LINK( HandleConnectButton, void * );
|
DECL_DLLPRIVATE_LINK( HandleConnectButton, void * );
|
||||||
DECL_LINK( CloseHdl, void * );
|
DECL_LINK( CloseHdl, void * );
|
||||||
public:
|
public:
|
||||||
RemoteDialog( Window* pWindow );
|
RemoteDialog( Window* pWindow );
|
||||||
~RemoteDialog();
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@@ -1,56 +0,0 @@
|
|||||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
|
||||||
/*
|
|
||||||
* This file is part of the LibreOffice project.
|
|
||||||
*
|
|
||||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
||||||
*/
|
|
||||||
#include "helpids.h"
|
|
||||||
#include <svx/svxids.hrc>
|
|
||||||
#include "RemoteDialog.hrc"
|
|
||||||
|
|
||||||
ModalDialog DLG_PAIR_REMOTE
|
|
||||||
{
|
|
||||||
|
|
||||||
HelpID = CMD_SID_REMOTE_DLG ;
|
|
||||||
OutputSize = TRUE ;
|
|
||||||
SVLook = TRUE ;
|
|
||||||
Size = MAP_APPFONT ( 200, 160 ) ;
|
|
||||||
Text [ en-US ] = "Impress Remote" ;
|
|
||||||
Moveable = TRUE ;
|
|
||||||
Closeable = TRUE ;
|
|
||||||
|
|
||||||
Control LB_SERVERS
|
|
||||||
{
|
|
||||||
//; HelpId = HID_SD_SLIDETRANSITIONPANE_LB_SLIDE_TRANSITIONS;
|
|
||||||
Border = TRUE ;
|
|
||||||
TabStop = TRUE ;
|
|
||||||
//; AutoVScroll = TRUE ;
|
|
||||||
//; Pos = MAP_APPFONT ( 0, 0 ) ;
|
|
||||||
Size = MAP_APPFONT( 200, 140 );
|
|
||||||
};
|
|
||||||
|
|
||||||
OKButton BTN_CONNECT
|
|
||||||
{
|
|
||||||
Pos = MAP_APPFONT ( 100, 146 ) ;
|
|
||||||
Size = MAP_APPFONT ( 50, 14 ) ;
|
|
||||||
TabStop = TRUE ;
|
|
||||||
Text [ en-US ] = "Connect" ;
|
|
||||||
DefButton = TRUE ;
|
|
||||||
};
|
|
||||||
CancelButton BTN_CANCEL
|
|
||||||
{
|
|
||||||
Pos = MAP_APPFONT ( 150, 146 ) ;
|
|
||||||
Size = MAP_APPFONT ( 50, 14 ) ;
|
|
||||||
Text [ en-US ] = "Close" ;
|
|
||||||
TabStop = TRUE ;
|
|
||||||
};
|
|
||||||
|
|
||||||
String STR_ENTER_PIN
|
|
||||||
{
|
|
||||||
Text [ en-US ] = "Enter PIN:";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
|
@@ -20,7 +20,6 @@
|
|||||||
#include "svtools/controldims.hrc"
|
#include "svtools/controldims.hrc"
|
||||||
|
|
||||||
#include "RemoteDialogClientBox.hxx"
|
#include "RemoteDialogClientBox.hxx"
|
||||||
#include "RemoteDialog.hrc"
|
|
||||||
#include "RemoteServer.hxx"
|
#include "RemoteServer.hxx"
|
||||||
|
|
||||||
#include "comphelper/processfactory.hxx"
|
#include "comphelper/processfactory.hxx"
|
||||||
@@ -28,6 +27,8 @@
|
|||||||
#include "com/sun/star/deployment/DependencyException.hpp"
|
#include "com/sun/star/deployment/DependencyException.hpp"
|
||||||
#include "com/sun/star/deployment/DeploymentException.hpp"
|
#include "com/sun/star/deployment/DeploymentException.hpp"
|
||||||
|
|
||||||
|
#include "glob.hrc"
|
||||||
|
|
||||||
using namespace ::com::sun::star;
|
using namespace ::com::sun::star;
|
||||||
|
|
||||||
namespace sd {
|
namespace sd {
|
||||||
@@ -63,8 +64,8 @@ ClientRemovedListener::~ClientRemovedListener()
|
|||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
// ClientBox
|
// ClientBox
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
ClientBox::ClientBox( Dialog* pParent, const SdResId& aId ) :
|
ClientBox::ClientBox( Window* pParent, WinBits nStyle ) :
|
||||||
Control( pParent, aId ),
|
Control( pParent, nStyle ),
|
||||||
m_bHasScrollBar( false ),
|
m_bHasScrollBar( false ),
|
||||||
m_bHasActive( false ),
|
m_bHasActive( false ),
|
||||||
m_bNeedsRecalc( true ),
|
m_bNeedsRecalc( true ),
|
||||||
@@ -75,15 +76,13 @@ ClientBox::ClientBox( Dialog* pParent, const SdResId& aId ) :
|
|||||||
m_nTopIndex( 0 ),
|
m_nTopIndex( 0 ),
|
||||||
m_nActiveHeight( 0 ),
|
m_nActiveHeight( 0 ),
|
||||||
m_nExtraHeight( 2 ),
|
m_nExtraHeight( 2 ),
|
||||||
m_aPinBox( this, SdResId( INPUT_PIN ) ),
|
m_aPinBox( this, 0 ),
|
||||||
m_aPinDescription( this, SdResId( TEXT_PIN ) ),
|
m_aScrollBar( this, WB_VERT )
|
||||||
m_pScrollBar( new ScrollBar( this, WB_VERT ) )
|
|
||||||
{
|
{
|
||||||
m_pScrollBar->SetScrollHdl( LINK( this, ClientBox, ScrollHdl ) );
|
m_aScrollBar.SetScrollHdl( LINK( this, ClientBox, ScrollHdl ) );
|
||||||
m_pScrollBar->EnableDrag();
|
m_aScrollBar.EnableDrag();
|
||||||
|
|
||||||
m_aPinBox.SetUseThousandSep(false);
|
m_aPinBox.SetUseThousandSep(false);
|
||||||
// m_aPinDescription.SetText( SD_RESSTR( STR_ENTER_PIN ) );
|
|
||||||
|
|
||||||
SetPaintTransparent( true );
|
SetPaintTransparent( true );
|
||||||
SetPosPixel( Point( RSC_SP_DLG_INNERBORDER_LEFT, RSC_SP_DLG_INNERBORDER_TOP ) );
|
SetPosPixel( Point( RSC_SP_DLG_INNERBORDER_LEFT, RSC_SP_DLG_INNERBORDER_TOP ) );
|
||||||
@@ -112,6 +111,20 @@ ClientBox::ClientBox( Dialog* pParent, const SdResId& aId ) :
|
|||||||
Show();
|
Show();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
extern "C" SAL_DLLPUBLIC_EXPORT Window* SAL_CALL makeClientBox(Window *pParent, VclBuilder::stringmap &rMap)
|
||||||
|
{
|
||||||
|
WinBits nWinStyle = WB_TABSTOP;
|
||||||
|
OString sBorder = VclBuilder::extractCustomProperty(rMap);
|
||||||
|
if (!sBorder.isEmpty())
|
||||||
|
nWinStyle |= WB_BORDER;
|
||||||
|
return new ClientBox(pParent, nWinStyle);
|
||||||
|
}
|
||||||
|
|
||||||
|
Size ClientBox::GetOptimalSize() const
|
||||||
|
{
|
||||||
|
return LogicToPixel(Size(200, 140), MAP_APPFONT);
|
||||||
|
}
|
||||||
|
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
ClientBox::~ClientBox()
|
ClientBox::~ClientBox()
|
||||||
{
|
{
|
||||||
@@ -151,7 +164,7 @@ void ClientBox::CalcActiveHeight( const long nPos )
|
|||||||
// Text entry height
|
// Text entry height
|
||||||
Size aSize = GetOutputSizePixel();
|
Size aSize = GetOutputSizePixel();
|
||||||
if ( m_bHasScrollBar )
|
if ( m_bHasScrollBar )
|
||||||
aSize.Width() -= m_pScrollBar->GetSizePixel().Width();
|
aSize.Width() -= m_aScrollBar.GetSizePixel().Width();
|
||||||
|
|
||||||
aSize.Width() -= ICON_OFFSET;
|
aSize.Width() -= ICON_OFFSET;
|
||||||
|
|
||||||
@@ -173,7 +186,7 @@ Rectangle ClientBox::GetEntryRect( const long nPos ) const
|
|||||||
Size aSize( GetOutputSizePixel() );
|
Size aSize( GetOutputSizePixel() );
|
||||||
|
|
||||||
if ( m_bHasScrollBar )
|
if ( m_bHasScrollBar )
|
||||||
aSize.Width() -= m_pScrollBar->GetSizePixel().Width();
|
aSize.Width() -= m_aScrollBar.GetSizePixel().Width();
|
||||||
|
|
||||||
if ( m_vEntries[ nPos ]->m_bActive )
|
if ( m_vEntries[ nPos ]->m_bActive )
|
||||||
aSize.Height() = m_nActiveHeight;
|
aSize.Height() = m_nActiveHeight;
|
||||||
@@ -334,11 +347,11 @@ void ClientBox::DrawRow( const Rectangle& rRect, const TClientBoxEntry pEntry )
|
|||||||
Size aBtnSize( m_aPinBox.GetSizePixel() );
|
Size aBtnSize( m_aPinBox.GetSizePixel() );
|
||||||
Point aBtnPos( aRect.Left(),
|
Point aBtnPos( aRect.Left(),
|
||||||
aRect.Bottom() - TOP_OFFSET - aBtnSize.Height() );
|
aRect.Bottom() - TOP_OFFSET - aBtnSize.Height() );
|
||||||
// m_aPinDescription.SetPosPixel( aBtnPos );
|
OUString sPinText(SD_RESSTR(STR_ENTER_PIN));
|
||||||
DrawText( Rectangle( aBtnPos.X(), aBtnPos.Y(), rRect.Right(), rRect.Bottom() - TOP_OFFSET),
|
DrawText( Rectangle( aBtnPos.X(), aBtnPos.Y(), rRect.Right(), rRect.Bottom() - TOP_OFFSET),
|
||||||
SD_RESSTR( STR_ENTER_PIN ), 0 );
|
sPinText, 0 );
|
||||||
|
|
||||||
aBtnPos = Point( aRect.Left() + GetTextWidth( SD_RESSTR( STR_ENTER_PIN ) ),
|
aBtnPos = Point( aRect.Left() + GetTextWidth( sPinText ),
|
||||||
aRect.Bottom() - TOP_OFFSET - aBtnSize.Height() );
|
aRect.Bottom() - TOP_OFFSET - aBtnSize.Height() );
|
||||||
|
|
||||||
m_aPinBox.SetPosPixel( aBtnPos );
|
m_aPinBox.SetPosPixel( aBtnPos );
|
||||||
@@ -407,7 +420,7 @@ void ClientBox::RecalcAll()
|
|||||||
}
|
}
|
||||||
|
|
||||||
if ( m_bHasScrollBar )
|
if ( m_bHasScrollBar )
|
||||||
m_pScrollBar->SetThumbPos( m_nTopIndex );
|
m_aScrollBar.SetThumbPos( m_nTopIndex );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -478,7 +491,7 @@ void ClientBox::Paint( const Rectangle &/*rPaintRect*/ )
|
|||||||
Size aSize( GetOutputSizePixel() );
|
Size aSize( GetOutputSizePixel() );
|
||||||
|
|
||||||
if ( m_bHasScrollBar )
|
if ( m_bHasScrollBar )
|
||||||
aSize.Width() -= m_pScrollBar->GetSizePixel().Width();
|
aSize.Width() -= m_aScrollBar.GetSizePixel().Width();
|
||||||
|
|
||||||
const ::osl::MutexGuard aGuard( m_entriesMutex );
|
const ::osl::MutexGuard aGuard( m_entriesMutex );
|
||||||
|
|
||||||
@@ -518,20 +531,20 @@ void ClientBox::SetupScrollBar()
|
|||||||
if ( m_nTopIndex + aSize.Height() > nTotalHeight )
|
if ( m_nTopIndex + aSize.Height() > nTotalHeight )
|
||||||
m_nTopIndex = nTotalHeight - aSize.Height();
|
m_nTopIndex = nTotalHeight - aSize.Height();
|
||||||
|
|
||||||
m_pScrollBar->SetPosSizePixel( Point( aSize.Width() - nScrBarSize, 0 ),
|
m_aScrollBar.SetPosSizePixel( Point( aSize.Width() - nScrBarSize, 0 ),
|
||||||
Size( nScrBarSize, aSize.Height() ) );
|
Size( nScrBarSize, aSize.Height() ) );
|
||||||
m_pScrollBar->SetRangeMax( nTotalHeight );
|
m_aScrollBar.SetRangeMax( nTotalHeight );
|
||||||
m_pScrollBar->SetVisibleSize( aSize.Height() );
|
m_aScrollBar.SetVisibleSize( aSize.Height() );
|
||||||
m_pScrollBar->SetPageSize( ( aSize.Height() * 4 ) / 5 );
|
m_aScrollBar.SetPageSize( ( aSize.Height() * 4 ) / 5 );
|
||||||
m_pScrollBar->SetLineSize( m_nStdHeight );
|
m_aScrollBar.SetLineSize( m_nStdHeight );
|
||||||
m_pScrollBar->SetThumbPos( m_nTopIndex );
|
m_aScrollBar.SetThumbPos( m_nTopIndex );
|
||||||
|
|
||||||
if ( !m_bHasScrollBar )
|
if ( !m_bHasScrollBar )
|
||||||
m_pScrollBar->Show();
|
m_aScrollBar.Show();
|
||||||
}
|
}
|
||||||
else if ( m_bHasScrollBar )
|
else if ( m_bHasScrollBar )
|
||||||
{
|
{
|
||||||
m_pScrollBar->Hide();
|
m_aScrollBar.Hide();
|
||||||
m_nTopIndex = 0;
|
m_nTopIndex = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -607,11 +620,11 @@ long ClientBox::Notify( NotifyEvent& rNEvt )
|
|||||||
const CommandWheelData* pData = rNEvt.GetCommandEvent()->GetWheelData();
|
const CommandWheelData* pData = rNEvt.GetCommandEvent()->GetWheelData();
|
||||||
if ( pData->GetMode() == COMMAND_WHEEL_SCROLL )
|
if ( pData->GetMode() == COMMAND_WHEEL_SCROLL )
|
||||||
{
|
{
|
||||||
long nThumbPos = m_pScrollBar->GetThumbPos();
|
long nThumbPos = m_aScrollBar.GetThumbPos();
|
||||||
if ( pData->GetDelta() < 0 )
|
if ( pData->GetDelta() < 0 )
|
||||||
m_pScrollBar->DoScroll( nThumbPos + m_nStdHeight );
|
m_aScrollBar.DoScroll( nThumbPos + m_nStdHeight );
|
||||||
else
|
else
|
||||||
m_pScrollBar->DoScroll( nThumbPos - m_nStdHeight );
|
m_aScrollBar.DoScroll( nThumbPos - m_nStdHeight );
|
||||||
bHandled = true;
|
bHandled = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -690,13 +703,13 @@ long ClientBox::addEntry( ClientInfo* pClientInfo )
|
|||||||
void ClientBox::DoScroll( long nDelta )
|
void ClientBox::DoScroll( long nDelta )
|
||||||
{
|
{
|
||||||
m_nTopIndex += nDelta;
|
m_nTopIndex += nDelta;
|
||||||
Point aNewSBPt( m_pScrollBar->GetPosPixel() );
|
Point aNewSBPt( m_aScrollBar.GetPosPixel() );
|
||||||
|
|
||||||
Rectangle aScrRect( Point(), GetOutputSizePixel() );
|
Rectangle aScrRect( Point(), GetOutputSizePixel() );
|
||||||
aScrRect.Right() -= m_pScrollBar->GetSizePixel().Width();
|
aScrRect.Right() -= m_aScrollBar.GetSizePixel().Width();
|
||||||
Scroll( 0, -nDelta, aScrRect );
|
Scroll( 0, -nDelta, aScrRect );
|
||||||
|
|
||||||
m_pScrollBar->SetPosPixel( aNewSBPt );
|
m_aScrollBar.SetPosPixel( aNewSBPt );
|
||||||
}
|
}
|
||||||
|
|
||||||
// -----------------------------------------------------------------------
|
// -----------------------------------------------------------------------
|
||||||
|
@@ -106,9 +106,8 @@ class ClientBox:
|
|||||||
Link m_aClickHdl;
|
Link m_aClickHdl;
|
||||||
|
|
||||||
NumericBox m_aPinBox;
|
NumericBox m_aPinBox;
|
||||||
FixedText m_aPinDescription;
|
|
||||||
|
|
||||||
ScrollBar* m_pScrollBar;
|
ScrollBar m_aScrollBar;
|
||||||
|
|
||||||
com::sun::star::uno::Reference< ClientRemovedListener > m_xRemoveListener;
|
com::sun::star::uno::Reference< ClientRemovedListener > m_xRemoveListener;
|
||||||
|
|
||||||
@@ -140,12 +139,13 @@ class ClientBox:
|
|||||||
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
ClientBox( Dialog* pParent, const SdResId& aId );
|
ClientBox( Window* pParent, WinBits nStyle );
|
||||||
~ClientBox();
|
~ClientBox();
|
||||||
|
|
||||||
void MouseButtonDown( const MouseEvent& rMEvt );
|
void MouseButtonDown( const MouseEvent& rMEvt );
|
||||||
void Paint( const Rectangle &rPaintRect );
|
void Paint( const Rectangle &rPaintRect );
|
||||||
void Resize();
|
void Resize();
|
||||||
|
Size GetOptimalSize() const;
|
||||||
long Notify( NotifyEvent& rNEvt );
|
long Notify( NotifyEvent& rNEvt );
|
||||||
|
|
||||||
const Size GetMinOutputSizePixel() const;
|
const Size GetMinOutputSizePixel() const;
|
||||||
|
@@ -1,18 +0,0 @@
|
|||||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
|
||||||
/*
|
|
||||||
* This file is part of the LibreOffice project.
|
|
||||||
*
|
|
||||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
||||||
*/
|
|
||||||
#include <sfx2/sfx.hrc>
|
|
||||||
|
|
||||||
#define DLG_PAIR_REMOTE RID_APP_START+700
|
|
||||||
|
|
||||||
#define BTN_CONNECT 1
|
|
||||||
#define BTN_CANCEL 2
|
|
||||||
#define LB_SERVERS 3
|
|
||||||
#define INPUT_PIN 4
|
|
||||||
#define TEXT_PIN 5
|
|
||||||
#define STR_ENTER_PIN 6
|
|
@@ -387,17 +387,11 @@ void TableValueSet::updateSettings()
|
|||||||
|
|
||||||
extern "C" SAL_DLLPUBLIC_EXPORT ::Window* SAL_CALL makeTableValueSet(::Window *pParent, VclBuilder::stringmap &rMap)
|
extern "C" SAL_DLLPUBLIC_EXPORT ::Window* SAL_CALL makeTableValueSet(::Window *pParent, VclBuilder::stringmap &rMap)
|
||||||
{
|
{
|
||||||
WinBits nWinBits = WB_TABSTOP;
|
WinBits nWinStyle = WB_TABSTOP;
|
||||||
|
OString sBorder = VclBuilder::extractCustomProperty(rMap);
|
||||||
VclBuilder::stringmap::iterator aFind = rMap.find(OString("border"));
|
if (!sBorder.isEmpty())
|
||||||
if (aFind != rMap.end())
|
nWinStyle |= WB_BORDER;
|
||||||
{
|
return new TableValueSet(pParent, nWinStyle);
|
||||||
if (toBool(aFind->second))
|
|
||||||
nWinBits |= WB_BORDER;
|
|
||||||
rMap.erase(aFind);
|
|
||||||
}
|
|
||||||
|
|
||||||
return new TableValueSet(pParent, nWinBits);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// --------------------------------------------------------------------
|
// --------------------------------------------------------------------
|
||||||
|
78
sd/uiconfig/simpress/ui/remotedialog.ui
Normal file
78
sd/uiconfig/simpress/ui/remotedialog.ui
Normal file
@@ -0,0 +1,78 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<interface>
|
||||||
|
<!-- interface-requires LibreOffice 1.0 -->
|
||||||
|
<!-- interface-requires gtk+ 3.0 -->
|
||||||
|
<object class="GtkDialog" id="RemoteDialog">
|
||||||
|
<property name="can_focus">False</property>
|
||||||
|
<property name="border_width">6</property>
|
||||||
|
<property name="title" translatable="yes">Impress Remote</property>
|
||||||
|
<property name="type_hint">dialog</property>
|
||||||
|
<child internal-child="vbox">
|
||||||
|
<object class="GtkBox" id="dialog-vbox1">
|
||||||
|
<property name="can_focus">False</property>
|
||||||
|
<property name="orientation">vertical</property>
|
||||||
|
<property name="spacing">12</property>
|
||||||
|
<child internal-child="action_area">
|
||||||
|
<object class="GtkButtonBox" id="dialog-action_area1">
|
||||||
|
<property name="can_focus">False</property>
|
||||||
|
<property name="margin_top">5</property>
|
||||||
|
<property name="layout_style">end</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkButton" id="connect">
|
||||||
|
<property name="label">gtk-connect</property>
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can_focus">True</property>
|
||||||
|
<property name="can_default">True</property>
|
||||||
|
<property name="has_default">True</property>
|
||||||
|
<property name="receives_default">True</property>
|
||||||
|
<property name="use_stock">True</property>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">0</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkButton" id="close">
|
||||||
|
<property name="label">gtk-close</property>
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can_focus">True</property>
|
||||||
|
<property name="receives_default">True</property>
|
||||||
|
<property name="use_stock">True</property>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">1</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="pack_type">end</property>
|
||||||
|
<property name="position">0</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="sduilo-ClientBox" id="tree:border">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can_focus">False</property>
|
||||||
|
<property name="hexpand">True</property>
|
||||||
|
<property name="vexpand">True</property>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">1</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
<action-widgets>
|
||||||
|
<action-widget response="0">connect</action-widget>
|
||||||
|
<action-widget response="0">close</action-widget>
|
||||||
|
</action-widgets>
|
||||||
|
</object>
|
||||||
|
</interface>
|
Reference in New Issue
Block a user