convert change chart data source dialog to .ui
Change-Id: Iecccfbcd6b1eaec9d14c594812293c3e2acfda46
This commit is contained in:
@@ -41,7 +41,6 @@ $(eval $(call gb_SrsTarget_add_files,sc/res,\
|
||||
sc/source/ui/src/sc.src \
|
||||
sc/source/ui/src/hdrcont.src \
|
||||
sc/source/ui/src/scerrors.src \
|
||||
sc/source/ui/src/miscdlgs.src \
|
||||
sc/source/ui/src/scstring.src \
|
||||
sc/source/ui/src/filter.src \
|
||||
sc/source/ui/src/condformatdlg.src \
|
||||
|
@@ -64,6 +64,7 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/scalc,\
|
||||
sc/uiconfig/scalc/ui/allheaderfooterdialog \
|
||||
sc/uiconfig/scalc/ui/analysisofvariancedialog \
|
||||
sc/uiconfig/scalc/ui/cellprotectionpage \
|
||||
sc/uiconfig/scalc/ui/changesourcedialog \
|
||||
sc/uiconfig/scalc/ui/chardialog \
|
||||
sc/uiconfig/scalc/ui/colorrowdialog \
|
||||
sc/uiconfig/scalc/ui/colwidthdialog \
|
||||
|
@@ -1043,7 +1043,6 @@
|
||||
#define RID_SCDLG_CONTACTS (SC_DIALOGS_START + 78)
|
||||
|
||||
#define RID_SCPAGE_STAT (SC_DIALOGS_START + 79)
|
||||
#define RID_SCDLG_CHARTCOLROW (SC_DIALOGS_START + 80)
|
||||
#define RID_SCDLG_AREAS (SC_DIALOGS_START + 81)
|
||||
|
||||
// popup for drop-mode in navigator
|
||||
|
@@ -338,7 +338,6 @@ public:
|
||||
ScDocument* pDoc,
|
||||
int nId) = 0;
|
||||
virtual AbstractScColRowLabelDlg * CreateScColRowLabelDlg (Window* pParent,
|
||||
int nId,
|
||||
sal_Bool bCol = false,
|
||||
sal_Bool bRow = false) = 0;
|
||||
|
||||
|
@@ -638,23 +638,11 @@ AbstractScAutoFormatDlg * ScAbstractDialogFactory_Impl::CreateScAutoFormatDlg( W
|
||||
}
|
||||
|
||||
AbstractScColRowLabelDlg * ScAbstractDialogFactory_Impl::CreateScColRowLabelDlg(Window* pParent,
|
||||
int nId,
|
||||
sal_Bool bCol ,
|
||||
sal_Bool bRow)
|
||||
{
|
||||
ScColRowLabelDlg* pDlg=NULL;
|
||||
switch ( nId )
|
||||
{
|
||||
case RID_SCDLG_CHARTCOLROW :
|
||||
pDlg = new ScColRowLabelDlg( pParent, bCol,bRow );
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
if ( pDlg )
|
||||
return new AbstractScColRowLabelDlg_Impl( pDlg );
|
||||
return 0;
|
||||
ScColRowLabelDlg* pDlg = new ScColRowLabelDlg( pParent, bCol,bRow );
|
||||
return new AbstractScColRowLabelDlg_Impl( pDlg );
|
||||
}
|
||||
|
||||
AbstractScSortWarningDlg* ScAbstractDialogFactory_Impl::CreateScSortWarningDlg( Window* pParent, const OUString& rExtendText, const OUString& rCurrentText )
|
||||
|
@@ -407,7 +407,6 @@ public:
|
||||
ScDocument* pDoc,
|
||||
int nId);
|
||||
virtual AbstractScColRowLabelDlg * CreateScColRowLabelDlg (Window* pParent,
|
||||
int nId,
|
||||
sal_Bool bCol = false,
|
||||
sal_Bool bRow = false);
|
||||
|
||||
|
@@ -332,7 +332,7 @@ void ScDocShell::Execute( SfxRequest& rReq )
|
||||
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
|
||||
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
|
||||
|
||||
AbstractScColRowLabelDlg* pDlg = pFact->CreateScColRowLabelDlg( pParent, RID_SCDLG_CHARTCOLROW, bRowHeaders, bColHeaders);
|
||||
AbstractScColRowLabelDlg* pDlg = pFact->CreateScColRowLabelDlg(pParent, bRowHeaders, bColHeaders);
|
||||
OSL_ENSURE(pDlg, "Dialog create fail!");
|
||||
if ( pDlg->Execute() == RET_OK )
|
||||
{
|
||||
|
@@ -22,47 +22,30 @@
|
||||
|
||||
#include <vcl/dialog.hxx>
|
||||
#include <vcl/button.hxx>
|
||||
#include <vcl/fixed.hxx>
|
||||
|
||||
#include "sc.hrc"
|
||||
#include "scresid.hxx"
|
||||
|
||||
//------------------------------------------------------------------------
|
||||
|
||||
class ScColRowLabelDlg : public ModalDialog
|
||||
{
|
||||
public:
|
||||
ScColRowLabelDlg( Window* pParent,
|
||||
sal_Bool bCol = false,
|
||||
sal_Bool bRow = false )
|
||||
: ModalDialog( pParent, ScResId( RID_SCDLG_CHARTCOLROW ) ),
|
||||
aFlColRow ( this, ScResId(6) ),
|
||||
aBtnRow ( this, ScResId(2) ),
|
||||
aBtnCol ( this, ScResId(1) ),
|
||||
aBtnOk ( this, ScResId(3) ),
|
||||
aBtnCancel ( this, ScResId(4) ),
|
||||
aBtnHelp ( this, ScResId(5) )
|
||||
{
|
||||
FreeResource();
|
||||
aBtnCol.Check( bCol );
|
||||
aBtnRow.Check( bRow );
|
||||
}
|
||||
ScColRowLabelDlg(Window* pParent,
|
||||
bool bCol = false,
|
||||
bool bRow = false)
|
||||
: ModalDialog(pParent, "ChangeSourceDialog",
|
||||
"modules/scalc/ui/changesourcedialog.ui")
|
||||
{
|
||||
get(m_pBtnRow, "row");
|
||||
get(m_pBtnCol, "col");
|
||||
m_pBtnCol->Check(bCol);
|
||||
m_pBtnRow->Check(bRow);
|
||||
}
|
||||
|
||||
sal_Bool IsCol() { return aBtnCol.IsChecked(); }
|
||||
sal_Bool IsRow() { return aBtnRow.IsChecked(); }
|
||||
bool IsCol() const { return m_pBtnCol->IsChecked(); }
|
||||
bool IsRow() const { return m_pBtnRow->IsChecked(); }
|
||||
|
||||
private:
|
||||
FixedLine aFlColRow;
|
||||
CheckBox aBtnRow;
|
||||
CheckBox aBtnCol;
|
||||
OKButton aBtnOk;
|
||||
CancelButton aBtnCancel;
|
||||
HelpButton aBtnHelp;
|
||||
CheckBox* m_pBtnRow;
|
||||
CheckBox* m_pBtnCol;
|
||||
};
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
||||
|
@@ -1,68 +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/.
|
||||
*
|
||||
* This file incorporates work covered by the following license notice:
|
||||
*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
* contributor license agreements. See the NOTICE file distributed
|
||||
* with this work for additional information regarding copyright
|
||||
* ownership. The ASF licenses this file to you under the Apache
|
||||
* License, Version 2.0 (the "License"); you may not use this file
|
||||
* except in compliance with the License. You may obtain a copy of
|
||||
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
|
||||
*/
|
||||
|
||||
#include "miscdlgs.hrc"
|
||||
|
||||
ModalDialog RID_SCDLG_CHARTCOLROW
|
||||
{
|
||||
HelpID = "sc:ModalDialog:RID_SCDLG_CHARTCOLROW";
|
||||
OutputSize = TRUE ;
|
||||
SVLook = TRUE ;
|
||||
Size = MAP_APPFONT ( 191 , 63 ) ;
|
||||
Moveable = TRUE ;
|
||||
CheckBox 1
|
||||
{
|
||||
HelpID = "sc:CheckBox:RID_SCDLG_CHARTCOLROW:1";
|
||||
Pos = MAP_APPFONT ( 12 , 28 ) ;
|
||||
Size = MAP_APPFONT ( 114 , 10 ) ;
|
||||
Text [ en-US ] = "First ~column as label" ;
|
||||
};
|
||||
CheckBox 2
|
||||
{
|
||||
HelpID = "sc:CheckBox:RID_SCDLG_CHARTCOLROW:2";
|
||||
Pos = MAP_APPFONT ( 12 , 14 ) ;
|
||||
Size = MAP_APPFONT ( 114 , 10 ) ;
|
||||
Text [ en-US ] = "First ~row as label" ;
|
||||
};
|
||||
FixedLine 6
|
||||
{
|
||||
Pos = MAP_APPFONT ( 6 , 3 ) ;
|
||||
Size = MAP_APPFONT ( 123 , 8 ) ;
|
||||
Text [ en-US ] = "Labels" ;
|
||||
};
|
||||
OKButton 3
|
||||
{
|
||||
Pos = MAP_APPFONT ( 135 , 6 ) ;
|
||||
Size = MAP_APPFONT ( 50 , 14 ) ;
|
||||
DefButton = TRUE ;
|
||||
};
|
||||
CancelButton 4
|
||||
{
|
||||
Pos = MAP_APPFONT ( 135 , 23 ) ;
|
||||
Size = MAP_APPFONT ( 50 , 14 ) ;
|
||||
};
|
||||
HelpButton 5
|
||||
{
|
||||
Pos = MAP_APPFONT ( 135 , 43 ) ;
|
||||
Size = MAP_APPFONT ( 50 , 14 ) ;
|
||||
};
|
||||
Text [ en-US ] = "Change Source Data Range" ;
|
||||
};
|
||||
|
||||
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
149
sc/uiconfig/scalc/ui/changesourcedialog.ui
Normal file
149
sc/uiconfig/scalc/ui/changesourcedialog.ui
Normal file
@@ -0,0 +1,149 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!-- Generated with glade 3.16.1 -->
|
||||
<interface>
|
||||
<requires lib="gtk+" version="3.0"/>
|
||||
<object class="GtkDialog" id="ChangeSourceDialog">
|
||||
<property name="can_focus">False</property>
|
||||
<property name="border_width">6</property>
|
||||
<property name="title" translatable="yes">Change Source Data Range</property>
|
||||
<property name="type_hint">normal</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="layout_style">end</property>
|
||||
<child>
|
||||
<object class="GtkButton" id="ok">
|
||||
<property name="label">gtk-ok</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="cancel">
|
||||
<property name="label">gtk-cancel</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>
|
||||
<child>
|
||||
<object class="GtkButton" id="help">
|
||||
<property name="label">gtk-help</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">2</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="GtkFrame" id="frame1">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="label_xalign">0</property>
|
||||
<property name="shadow_type">none</property>
|
||||
<child>
|
||||
<object class="GtkAlignment" id="alignment1">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="top_padding">6</property>
|
||||
<property name="left_padding">12</property>
|
||||
<child>
|
||||
<object class="GtkGrid" id="grid3">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="row_spacing">6</property>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="col">
|
||||
<property name="label" translatable="yes">First _column as label</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="xalign">0</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="width">1</property>
|
||||
<property name="height">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="row">
|
||||
<property name="label" translatable="yes">First _row as label</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="xalign">0</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="width">1</property>
|
||||
<property name="height">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
<child type="label">
|
||||
<object class="GtkLabel" id="label1">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="label" translatable="yes">Labels</property>
|
||||
<attributes>
|
||||
<attribute name="weight" value="bold"/>
|
||||
</attributes>
|
||||
</object>
|
||||
</child>
|
||||
</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">help</action-widget>
|
||||
</action-widgets>
|
||||
</object>
|
||||
</interface>
|
Reference in New Issue
Block a user