Tag: cws_src680_oj14
User: oj      
Date: 2006/07/04 00:50:12

Modified:
   dba/dbaccess/source/ui/control/FieldDescControl.cxx

Log:
 RESYNC: (1.41-1.42); FILE MERGED

File Changes:

Directory: /dba/dbaccess/source/ui/control/
===========================================

File [changed]: FieldDescControl.cxx
Url: 
http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/control/FieldDescControl.cxx?r1=1.41.4.3&r2=1.41.4.4
Delta lines:  +71 -66
---------------------
--- FieldDescControl.cxx        25 Apr 2006 12:51:36 -0000      1.41.4.3
+++ FieldDescControl.cxx        4 Jul 2006 07:50:10 -0000       1.41.4.4
@@ -147,12 +147,11 @@
 
 using namespace dbaui;
 using namespace dbtools;
-//     using namespace comphelper;
 using namespace ::com::sun::star::uno;
 using namespace ::com::sun::star::beans;
 using namespace ::com::sun::star::lang;
 using namespace ::com::sun::star::sdbc;
-//     using namespace ::com::sun::star::sdb;
+using namespace ::com::sun::star::util;
 
 //==================================================================
 
@@ -194,49 +193,53 @@
 // class OFieldDescControl
 //==================================================================
 
-DBG_NAME(OFieldDescControl);
+DBG_NAME(OFieldDescControl)
 
 //==================================================================
 OFieldDescControl::OFieldDescControl( Window* pParent, const ResId& rResId, 
OTableDesignHelpBar* pHelpBar)
        :TabPage( pParent, rResId )
-       ,m_pPreviousType()
        ,pHelp( pHelpBar )
-       ,nCurChildId(1)
-       ,pDefault(NULL)
+       ,pLastFocusWindow(NULL)
+       ,m_pActFocusWindow(NULL)
        ,pDefaultText(NULL)
-       ,pRequired(NULL)
        ,pRequiredText(NULL)
-       ,pAutoIncrement(NULL)
        ,pAutoIncrementText(NULL)
-       ,pTextLen(NULL)
        ,pTextLenText(NULL)
-       ,pNumType(NULL)
        ,pNumTypeText(NULL)
-       ,pLastFocusWindow(NULL)
-       ,pFormatSample(NULL)
-       ,pFormatText(NULL)
-       ,pFormat(NULL)
-       ,pLength(NULL)
        ,pLengthText(NULL)
-       ,pScale(NULL)
        ,pScaleText(NULL)
-       ,pBoolDefault(NULL)
+       ,pFormatText(NULL)
        ,pBoolDefaultText(NULL)
-       ,m_pColumnName(NULL)
        ,m_pColumnNameText(NULL)
-       ,m_pType(NULL)
        ,m_pTypeText(NULL)
        ,m_pAutoIncrementValueText(NULL)
+       ,pRequired(NULL)
+       ,pNumType(NULL)
+       ,pAutoIncrement(NULL)
+       ,pDefault(NULL)
+       ,pTextLen(NULL)
+       ,pLength(NULL)
+       ,pScale(NULL)
+       ,pFormatSample(NULL)
+       ,pBoolDefault(NULL)
+       ,m_pColumnName(NULL)
+       ,m_pType(NULL)
        ,m_pAutoIncrementValue(NULL)
+       ,pFormat(NULL)
+    ,m_pVertScroll( NULL )
+    ,m_pHorzScroll( NULL )
+    ,m_pPreviousType()
+       ,nCurChildId(1)
        ,m_nPos(-1)
        ,aYes(ModuleRes(STR_VALUE_YES))
        ,aNo(ModuleRes(STR_VALUE_NO))
-       ,nDelayedGrabFocusEvent(0)
-       ,pActFieldDescr(NULL)
-       ,m_pActFocusWindow(NULL)
-       ,m_bRight(sal_False)
+    ,m_nOldVThumb( 0 )
+    ,m_nOldHThumb( 0 )
        ,m_nWidth(50)
+    ,nDelayedGrabFocusEvent(0)
     ,m_bAdded(sal_False)
+       ,m_bRightAligned(false)
+    ,pActFieldDescr(NULL)
 {
        DBG_CTOR(OFieldDescControl,NULL);
 
@@ -260,44 +263,48 @@
 
//------------------------------------------------------------------------------
 OFieldDescControl::OFieldDescControl( Window* pParent, OTableDesignHelpBar* 
pHelpBar )
        :TabPage( pParent, WB_3DLOOK | WB_DIALOGCONTROL )
-       ,m_pPreviousType()
        ,pHelp( pHelpBar )
-       ,nCurChildId(1)
-       ,pDefault(NULL)
+       ,pLastFocusWindow(NULL)
+       ,m_pActFocusWindow(NULL)
        ,pDefaultText(NULL)
-       ,pRequired(NULL)
        ,pRequiredText(NULL)
-       ,pAutoIncrement(NULL)
        ,pAutoIncrementText(NULL)
-       ,pTextLen(NULL)
        ,pTextLenText(NULL)
-       ,pNumType(NULL)
        ,pNumTypeText(NULL)
-       ,pLastFocusWindow(NULL)
-       ,pFormatSample(NULL)
-       ,pFormatText(NULL)
-       ,pFormat(NULL)
-       ,pLength(NULL)
        ,pLengthText(NULL)
-       ,pScale(NULL)
        ,pScaleText(NULL)
-       ,pBoolDefault(NULL)
+       ,pFormatText(NULL)
        ,pBoolDefaultText(NULL)
-       ,m_pColumnName(NULL)
        ,m_pColumnNameText(NULL)
-       ,m_pType(NULL)
        ,m_pTypeText(NULL)
        ,m_pAutoIncrementValueText(NULL)
+       ,pRequired(NULL)
+       ,pNumType(NULL)
+       ,pAutoIncrement(NULL)
+       ,pDefault(NULL)
+       ,pTextLen(NULL)
+       ,pLength(NULL)
+       ,pScale(NULL)
+       ,pFormatSample(NULL)
+       ,pBoolDefault(NULL)
+       ,m_pColumnName(NULL)
+       ,m_pType(NULL)
        ,m_pAutoIncrementValue(NULL)
+       ,pFormat(NULL)
+    ,m_pVertScroll( NULL )
+    ,m_pHorzScroll( NULL )
+    ,m_pPreviousType()
+       ,nCurChildId(1)
        ,m_nPos(-1)
        ,aYes(ModuleRes(STR_VALUE_YES))
        ,aNo(ModuleRes(STR_VALUE_NO))
-       ,nDelayedGrabFocusEvent(0)
-       ,pActFieldDescr(0)
-       ,m_pActFocusWindow(NULL)
-       ,m_bRight(sal_False)
+    ,m_nOldVThumb( 0 )
+    ,m_nOldHThumb( 0 )
        ,m_nWidth(50)
+    ,nDelayedGrabFocusEvent(0)
     ,m_bAdded(sal_False)
+       ,m_bRightAligned(false)
+    ,pActFieldDescr(NULL)
 {
        DBG_CTOR(OFieldDescControl,NULL);
 
@@ -361,8 +368,6 @@
 {
        static String aZero('0');
        static String aOne('1');
-       static String aNo(ModuleRes(STR_VALUE_NO));
-       static String aYes(ModuleRes(STR_VALUE_YES));
 
        if (rUIString == aNo)
                return aZero;
@@ -376,8 +381,6 @@
 {
        static String aZero('0');
        static String aOne('1');
-       static String aYes(ModuleRes(STR_VALUE_YES));
-       static String aNo(ModuleRes(STR_VALUE_NO));
        static String aNone(ModuleRes(STR_VALUE_NONE));
 
        // FS - 66161 - 14.05.1999 - aeltere Versionen haben eventuell einen 
sprachabhaengigen String als Default gespeichert
@@ -400,7 +403,7 @@
 }
 
 
//------------------------------------------------------------------------------
-IMPL_LINK(OFieldDescControl, OnScroll, ScrollBar*, pBar)
+IMPL_LINK(OFieldDescControl, OnScroll, ScrollBar*, /*pBar*/)
 {
        ScrollAllAggregates();
        return 0;
@@ -738,7 +741,7 @@
 }
 
 //------------------------------------------------------------------------
-IMPL_LINK( OFieldDescControl, FormatClickHdl, Button *, pButton )
+IMPL_LINK( OFieldDescControl, FormatClickHdl, Button *, /*pButton*/ )
 {
        DBG_CHKTHIS(OFieldDescControl,NULL);
        //////////////////////////////////////////////////////////////////////
@@ -748,10 +751,8 @@
 
        sal_Int32 nOldFormatKey(pActFieldDescr->GetFormatKey());
        SvxCellHorJustify rOldJustify = pActFieldDescr->GetHorJustify();
-       Reference< ::com::sun::star::util::XNumberFormatsSupplier >  xSupplier 
= GetFormatter()->getNumberFormatsSupplier();
-
-       Reference< XUnoTunnel > xTunnel(xSupplier,UNO_QUERY);
-       SvNumberFormatsSupplierObj* pSupplierImpl = 
(SvNumberFormatsSupplierObj*)xTunnel->getSomething(SvNumberFormatsSupplierObj::getUnoTunnelId());
+       Reference< XNumberFormatsSupplier >  xSupplier = 
GetFormatter()->getNumberFormatsSupplier();
+    SvNumberFormatsSupplierObj* pSupplierImpl = 
SvNumberFormatsSupplierObj::getImplementation( xSupplier );
 
        SvNumberFormatter* pFormatter = pSupplierImpl->GetNumberFormatter();
        sal_uInt16 nFlags;
@@ -778,6 +779,10 @@
        return 0;
 }
 
+// -----------------------------------------------------------------------
+void OFieldDescControl::SetModified(sal_Bool /*bModified*/) 
+{
+}
 //------------------------------------------------------------------------
 IMPL_LINK( OFieldDescControl, ChangeHdl, ListBox *, pListBox )
 {
@@ -880,7 +885,7 @@
        };
 
        long nMaxWidth = 0;
-       for (int i=0; i<sizeof(adAggregates)/sizeof(adAggregates[0]); i++)
+       for (size_t i=0; i<sizeof(adAggregates)/sizeof(adAggregates[0]); i++)
        {
                if (adAggregates[i].pctrlTextControl)
                {
@@ -893,7 +898,7 @@
        // und los ...
        int nCurrentControlPos = 0;
        Control* pZOrderPredecessor = NULL;
-       for (int i=0; i<sizeof(adAggregates)/sizeof(adAggregates[0]); i++)
+       for (size_t i=0; i<sizeof(adAggregates)/sizeof(adAggregates[0]); i++)
        {
                if (adAggregates[i].pctrlInputControl)
                {
@@ -1410,35 +1415,35 @@
                aSize.Height() = CONTROL_HEIGHT;
                break;
        case 1:
-               if ( m_bRight )
+               if ( isRightAligned() )
                        aSize.Width() = LogicToPixel(Size(m_nWidth, 
0),MAP_APPFONT).Width();
                else
                        aSize.Width()  = CONTROL_WIDTH_2;
                aSize.Height() = CONTROL_HEIGHT;
                break;
        case 2:
-               if ( m_bRight )
+               if ( isRightAligned() )
                        aSize.Width() = LogicToPixel(Size(m_nWidth, 
0),MAP_APPFONT).Width();
                else
                        aSize.Width()  = CONTROL_WIDTH_2;
                aSize.Height() = long(1.5*CONTROL_HEIGHT);
                break;
        case 3:
-               if ( m_bRight )
+               if ( isRightAligned() )
                        aSize.Width() = LogicToPixel(Size(m_nWidth, 
0),MAP_APPFONT).Width();
                else
                        aSize.Width()  = CONTROL_WIDTH_3;
                aSize.Height() = CONTROL_HEIGHT;
                break;
        case 4:
-               if ( m_bRight )
+               if ( isRightAligned() )
                        aSize.Width() = LogicToPixel(Size(m_nWidth, 
0),MAP_APPFONT).Width();
                else
                        aSize.Width()  = CONTROL_WIDTH_4;
                aSize.Height() = CONTROL_HEIGHT;
                break;
        default:
-               if ( m_bRight )
+               if ( isRightAligned() )
                        aSize.Width() = LogicToPixel(Size(m_nWidth, 
0),MAP_APPFONT).Width();
                else
                        aSize.Width()  = CONTROL_WIDTH_1;
@@ -1459,7 +1464,7 @@
        case 2:
        case 3:
        case 4:
-               if ( m_bRight )
+               if ( isRightAligned() )
                {
                        Size aOwnSize = GetSizePixel();
                        aPosition.X() = aOwnSize.Width() - aSize.Width();




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to