Kaydet (Commit) 145aa21e authored tarafından Cao Cuong Ngo's avatar Cao Cuong Ngo Kaydeden (comit) Cédric Bosdonnat

CMIS properties dialog

Change property name and type to FixedText

Change-Id: I568e213efb0cd0fb0167d8dab397f67b3fa1f69e
üst dbfbfd08
......@@ -525,19 +525,6 @@ public:
inline CmisPropertyLine* GetLine() const { return m_pLine; }
};
class CmisPropertiesTypeBox : public ListBox
{
private:
CmisPropertyLine* m_pLine;
public:
inline CmisPropertiesTypeBox(
Window* pParent, const ResId& rResId, CmisPropertyLine* pLine ) :
ListBox( pParent, rResId ), m_pLine( pLine ) {}
inline CmisPropertyLine* GetLine() const { return m_pLine; }
};
class CmisPropertiesDateField : public DateField
{
private:
......@@ -594,20 +581,17 @@ public:
struct CmisPropertyLine
{
SelectableFixedText m_aNameBox;
CmisPropertiesTypeBox m_aTypeBox;
FixedText m_aName;
FixedText m_aType;
CmisPropertiesEdit m_aValueEdit;
CmisPropertiesDateField m_aDateField;
CmisPropertiesTimeField m_aTimeField;
CmisPropertiesYesNoButton m_aYesNoButton;
Point m_aDatePos;
Point m_aTimePos;
Size m_aDateTimeSize;
bool m_bTypeLostFocus;
Point m_aDatePos;
Point m_aTimePos;
Size m_aDateTimeSize;
bool m_bTypeLostFocus;
CmisPropertyLine( Window* pParent );
void SetRemoved();
};
// class CmisPropertiesWindow ------------------------------------------
......@@ -615,8 +599,8 @@ struct CmisPropertyLine
class CmisPropertiesWindow : public Window
{
private:
SelectableFixedText m_aNameBox;
ListBox m_aTypeBox;
FixedText m_aName;
FixedText m_aType;
Edit m_aValueEdit;
DateField m_aDateField;
TimeField m_aTimeField;
......@@ -631,9 +615,7 @@ private:
Timer m_aEditLoseFocusTimer;
Timer m_aBoxLoseFocusTimer;
DECL_LINK( TypeHdl, CmisPropertiesTypeBox* );
DECL_LINK( EditLoseFocusHdl, CmisPropertiesEdit* );
DECL_LINK( BoxLoseFocusHdl, CmisPropertiesTypeBox* );
bool IsLineValid( CmisPropertyLine* pLine ) const;
void ValidateLine( CmisPropertyLine* pLine, bool bIsFromTypeBox );
......@@ -646,7 +628,7 @@ public:
~CmisPropertiesWindow();
void InitControls( HeaderBar* pHeaderBar, const ScrollBar* pScrollBar );
sal_uInt16 GetVisibleLineCount() const;
sal_uInt16 GetLineCount() const;
inline sal_Int32 GetLineHeight() const { return m_nLineHeight; }
void AddLine( const OUString& sName, com::sun::star::uno::Any& rAny );
bool AreAllLinesValid() const;
......@@ -697,7 +679,7 @@ private:
protected:
SfxCmisPropertiesPage( Window* pParent, const SfxItemSet& );
virtual sal_Bool FillItemSet( SfxItemSet& );
virtual sal_Bool FillItemSet( SfxItemSet& );
virtual void Reset( const SfxItemSet& );
virtual int DeactivatePage( SfxItemSet* pSet = NULL );
......
This diff is collapsed.
......@@ -31,11 +31,11 @@
#define CUSTOM_TYPE_DURATION 5
#define CUSTOM_TYPE_DATETIME 6
#define CMIS_TYPE_ANY 0
#define CMIS_TYPE_STRING 1
#define CMIS_TYPE_NUMBER 2
#define CMIS_TYPE_DATETIME 3
#define CMIS_TYPE_BOOLEAN 4
#define CMIS_TYPE_ANY "Any"
#define CMIS_TYPE_STRING "String"
#define CMIS_TYPE_NUMBER "Number"
#define CMIS_TYPE_DATETIME "Datetime"
#define CMIS_TYPE_BOOLEAN "Boolean"
// defines ---------------------------------------------------------------
......
......@@ -90,22 +90,6 @@ ListBox SFX_LB_PROPERTY_TYPE
< "Yes or no" ; CUSTOM_TYPE_BOOLEAN ; > ;
};
};
ListBox SFX_LB_CMIS_PROPERTY_TYPE
{
Pos = MAP_APPFONT ( 63 , 2 ) ;
Size = MAP_APPFONT ( 60 , 80 ) ;
DropDown = TRUE;
Border = TRUE;
CurPos = 0;
StringList [ en-US ] =
{
< "Text" ; CMIS_TYPE_STRING ; > ;
< "DateTime" ; CMIS_TYPE_DATETIME ; > ;
< "Integer" ; CMIS_TYPE_NUMBER ; > ;
< "Decimal" ; CMIS_TYPE_NUMBER ; > ;
< "Boolean" ; CMIS_TYPE_BOOLEAN ; > ;
};
};
Edit SFX_ED_PROPERTY_VALUE
{
......@@ -379,9 +363,73 @@ ModalDialog RID_EDIT_DURATIONS
SpinSize = 1 ;
Value = 0 ;
};
};
FixedText SFX_CMIS_PROPERTY_NAME
{
Pos = MAP_APPFONT ( 0 , 2 ) ;
Size = MAP_APPFONT ( 41 , RSC_CD_FIXEDTEXT_HEIGHT ) ;
Left = TRUE ;
};
FixedText SFX_CMIS_PROPERTY_TYPE
{
Pos = MAP_APPFONT ( 40 , 2 ) ;
Size = MAP_APPFONT ( 40 , RSC_CD_FIXEDTEXT_HEIGHT ) ;
Left = TRUE ;
};
Edit SFX_CMIS_ED_PROPERTY_VALUE
{
Border = TRUE ;
Pos = MAP_APPFONT ( 127 , 2 ) ;
Size = MAP_APPFONT ( 61 , RSC_CD_TEXTBOX_HEIGHT ) ;
TabStop = TRUE ;
Left = TRUE ;
};
DateField SFX_CMIS_FLD_DATE
{
Border = TRUE ;
Pos = MAP_APPFONT ( 127 , 2 ) ;
Size = MAP_APPFONT ( 29 , RSC_CD_TEXTBOX_HEIGHT ) ;
TabStop = TRUE ;
Left = TRUE ;
Spin = TRUE;
};
TimeField SFX_CMIS_FLD_TIME
{
Border = TRUE ;
Pos = MAP_APPFONT ( 159 , 2 ) ;
Size = MAP_APPFONT ( 29 , RSC_CD_TEXTBOX_HEIGHT ) ;
TabStop = TRUE ;
Left = TRUE ;
Spin = TRUE;
};
Control SFX_CMIS_WIN_PROPERTY_YESNO
{
HelpId = HID_CTRL_CUSTOMPROPS_YES_NO;
OutputSize = TRUE ;
Pos = MAP_APPFONT ( 127 , 2 ) ;
Size = MAP_APPFONT ( 61 , RSC_CD_TEXTBOX_HEIGHT ) ;
Border = TRUE ;
DialogControl = TRUE ;
RadioButton RB_PROPERTY_YES
{
TabStop = TRUE ;
Pos = MAP_APPFONT( 1 , 1 ) ;
Size = MAP_APPFONT( 28 , RSC_CD_RADIOBUTTON_HEIGHT ) ;
Text [ en-US ] = "Yes" ;
};
RadioButton RB_PROPERTY_NO
{
TabStop = TRUE ;
Pos = MAP_APPFONT( 32 , 1 ) ;
Size = MAP_APPFONT( 29 , RSC_CD_RADIOBUTTON_HEIGHT ) ;
Text [ en-US ] = "No" ;
};
};
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
......@@ -49,7 +49,14 @@
#define SFX_FLD_TIME (RID_SFX_SFXLOCAL_START + 11)
#define SFX_FLD_DURATION (RID_SFX_SFXLOCAL_START + 12)
#define SFX_ST_DURATION_FORMAT (RID_SFX_SFXLOCAL_START + 13)
#define SFX_LB_CMIS_PROPERTY_TYPE (RID_SFX_SFXLOCAL_START + 14)
#define SFX_CMIS_PROPERTY_NAME (RID_SFX_SFXLOCAL_START + 14)
#define SFX_CMIS_ED_PROPERTY_VALUE (RID_SFX_SFXLOCAL_START + 15)
#define SFX_CMIS_PROPERTY_TYPE (RID_SFX_SFXLOCAL_START + 16)
#define SFX_CMIS_WIN_PROPERTY_YESNO (RID_SFX_SFXLOCAL_START + 17)
#define SFX_CMIS_QB_WRONG_TYPE (RID_SFX_SFXLOCAL_START + 18)
#define SFX_CMIS_FLD_DATE (RID_SFX_SFXLOCAL_START + 19)
#define SFX_CMIS_FLD_TIME (RID_SFX_SFXLOCAL_START + 20)
// Images ----------------------------------------------------------------
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment