summaryrefslogtreecommitdiff
path: root/toolkit
diff options
context:
space:
mode:
authorPovilas Kanapickas <povilas.kanapickas@gmail.com>2010-10-18 16:52:05 +0100
committerMichael Meeks <michael.meeks@novell.com>2010-10-18 16:52:27 +0100
commit849a713ffd29a58ae79e48f80835c28bbd9d5a72 (patch)
tree7d2c662f43a00f3bc04a0d51c685544074538a5c /toolkit
parentf7cbde525450a1a9427873c264791c65056c4f2a (diff)
remove non-compiled code
Diffstat (limited to 'toolkit')
-rw-r--r--toolkit/source/awt/vclxtabcontrol.cxx22
-rw-r--r--toolkit/source/awt/vclxtabpage.cxx14
-rw-r--r--toolkit/source/awt/vclxtopwindow.cxx10
-rw-r--r--toolkit/source/layout/core/container.cxx41
-rw-r--r--toolkit/source/layout/core/helper.cxx69
-rw-r--r--toolkit/source/layout/core/import.hxx48
-rw-r--r--toolkit/source/layout/core/proplist.cxx25
-rw-r--r--toolkit/source/layout/core/root.cxx18
-rw-r--r--toolkit/source/layout/vcl/wrapper.cxx63
-rw-r--r--toolkit/workben/layout/editor.cxx94
-rw-r--r--toolkit/workben/layout/zoom.cxx10
11 files changed, 0 insertions, 414 deletions
diff --git a/toolkit/source/awt/vclxtabcontrol.cxx b/toolkit/source/awt/vclxtabcontrol.cxx
index a244605f55de..0cfc90a53c04 100644
--- a/toolkit/source/awt/vclxtabcontrol.cxx
+++ b/toolkit/source/awt/vclxtabcontrol.cxx
@@ -110,19 +110,6 @@ void SAL_CALL VCLXTabControl::dispose( ) throw(uno::RuntimeException)
VCLXWindow::dispose();
}
-#if 0
-void SAL_CALL VCLXTabControl::addTabListener( const Reference< XTabListener >& listener ) throw (uno::RuntimeException)
-{
- if ( listener.is() )
- maTabListeners.addInterface( listener );
-}
-
-void SAL_CALL VCLXTabControl::removeTabListener( const Reference< XTabListener >& listener ) throw (uno::RuntimeException)
-{
- if ( listener.is() )
- maTabListeners.removeInterface( listener );
-}
-#endif
TabControl *VCLXTabControl::getTabControl() const throw (uno::RuntimeException)
{
@@ -318,9 +305,6 @@ void SAL_CALL VCLXTabControl::allocateArea (awt::Rectangle const &area)
// LATER: Nah, the proper fix is to get the XWindow hierarchy
// straight.
-#if 0
- setPosSize( area.X, area.Y, area.Width, area.Height, awt::PosSize::POSSIZE );
-#else
awt::Size currentSize = getSize();
awt::Size requestedSize (area.Width, area.Height);
// requestedSize.Height = getHeightForWidth( area.Width );
@@ -377,7 +361,6 @@ void SAL_CALL VCLXTabControl::allocateArea (awt::Rectangle const &area)
if ( requestedSize.Height > currentSize.Height + 10)
setPosSize( 0, 0, 0, requestedSize.Height, awt::PosSize::HEIGHT );
}
-#endif
if (pageBasedSize.Width > parentSize.Width ()
|| pageBasedSize.Height > parentSize.Height ())
@@ -401,12 +384,7 @@ void SAL_CALL VCLXTabControl::allocateArea (awt::Rectangle const &area)
// HACK: since our layout:: container don't implement XWindow, we have no easy
// way to set them invisible; lets just set all their children as such :P
-#if 0
- if ( xWin.is() )
- xWin->setVisible( active );
-#else
setChildrenVisible( xChild, active );
-#endif
if ( active )
{
diff --git a/toolkit/source/awt/vclxtabpage.cxx b/toolkit/source/awt/vclxtabpage.cxx
index 49b9038ac1de..2f80ce3dca6a 100644
--- a/toolkit/source/awt/vclxtabpage.cxx
+++ b/toolkit/source/awt/vclxtabpage.cxx
@@ -109,20 +109,6 @@ void SAL_CALL VCLXTabPage::allocateArea( awt::Rectangle const& area )
OSL_TRACE ("%s: window: %d, %d", __FUNCTION__, windowSize.Width(), windowSize.Height() );
#endif
-#if 0
- if (requestedSize.Width > parentSize.Width ()
- || requestedSize.Height > parentSize.Height ())
- {
-#ifndef __SUNPRO_CC
- OSL_TRACE ("%s: ***setting parent: %d, %d", __FUNCTION__, requestedSize.Width, requestedSize.Height );
-#endif
- parent->SetSizePixel ( Size (requestedSize.Width, requestedSize.Height) );
-
- if (Window *grand_parent = parent->GetParent ())
- grand_parent->SetSizePixel ( Size (requestedSize.Width, requestedSize.Height) );
- }
-#endif
-
if ( !bRealized )
{
setPosSize( area.X, area.Y, requestedSize.Width, requestedSize.Height, awt::PosSize::SIZE );
diff --git a/toolkit/source/awt/vclxtopwindow.cxx b/toolkit/source/awt/vclxtopwindow.cxx
index 4fb348ad1a95..66e5e7b35e8b 100644
--- a/toolkit/source/awt/vclxtopwindow.cxx
+++ b/toolkit/source/awt/vclxtopwindow.cxx
@@ -157,16 +157,6 @@ void VCLXTopWindow_Base::toFront( ) throw(::com::sun::star::uno::RuntimeExcepti
void VCLXTopWindow_Base::toBack( ) throw(::com::sun::star::uno::RuntimeException)
{
-#if 0 // Not possible in VCL...
-
- ::vos::OGuard aGuard( GetMutexImpl() );
-
- Window* pWindow = GetWindowImpl();
- if ( pWindow )
- {
- ((WorkWindow*)pWindow)->ToBack();
- }
-#endif
}
void VCLXTopWindow_Base::setMenuBar( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XMenuBar >& rxMenu ) throw(::com::sun::star::uno::RuntimeException)
diff --git a/toolkit/source/layout/core/container.cxx b/toolkit/source/layout/core/container.cxx
index 7c7556a79929..f5822bc4569a 100644
--- a/toolkit/source/layout/core/container.cxx
+++ b/toolkit/source/layout/core/container.cxx
@@ -104,10 +104,6 @@ Container::setChildParent( const uno::Reference< awt::XLayoutConstrains >& xChil
if ( xContChild.is() )
{
xContChild->setParent( uno::Reference< awt::XLayoutContainer >( this ) );
-#if 0
- assert( !mxLayoutUnit.is() );
- xContChild->setLayoutUnit( mxLayoutUnit );
-#endif
}
}
@@ -118,46 +114,9 @@ Container::unsetChildParent( const uno::Reference< awt::XLayoutConstrains >& xCh
if ( xContChild.is() )
{
xContChild->setParent( uno::Reference< awt::XLayoutContainer >() );
-#if 0
- xContChild->setLayoutUnit( uno::Reference< awt::XLayoutUnit >() );
-#endif
}
}
-#if 0
-std::string
-Container::getLabel() // debug label
-{
- std::string depth;
- uno::Reference< awt::XLayoutContainer > xContainer( this );
- while ( xContainer.is() )
- {
- int node = 0; // child nb
- uno::Reference< awt::XLayoutContainer > xParent = xContainer->getContainerParent();
- if ( xParent.is() )
- {
-
- uno::Sequence< uno::Reference< awt::XLayoutConstrains > > aChildren;
- aChildren = xParent->getChildren();
- for ( node = 0; node < aChildren.getLength(); node++ )
- if ( aChildren[ node ] == xContainer )
- break;
- }
-
- char str[ 8 ];
- snprintf( str, 8, "%d", node );
- if ( depth.empty() )
- depth = std::string( str );
- else
- depth = std::string( str ) + ":" + depth;
-
- xContainer = xParent;
- }
-
- return std::string( getName() ) + " (" + depth + ")";
-}
-#endif
-
void Container::propertiesChanged()
{
// cl: why this assertion? This is also called to set properties at the top level widget which has no parent!?
diff --git a/toolkit/source/layout/core/helper.cxx b/toolkit/source/layout/core/helper.cxx
index 70e1f82dce51..1434054d8cf9 100644
--- a/toolkit/source/layout/core/helper.cxx
+++ b/toolkit/source/layout/core/helper.cxx
@@ -70,26 +70,6 @@ getParent( uno::Reference< uno::XInterface > xRef )
return uno::Reference< awt::XWindowPeer >();
}
-#if 0
-static uno::Reference< awt::XWindowPeer >
-getToplevel( uno::Reference< uno::XInterface > xRef )
-{
- uno::Reference< awt::XWindowPeer > xTop, i;
- while ( ( i = uno::Reference< awt::XWindowPeer >( xRef, uno::UNO_QUERY ) ).is() )
- {
- xTop = i;
-
- uno::Reference< awt::XLayoutContainer > xCont( xRef, uno::UNO_QUERY );
- if ( xCont.is() )
- xRef = xCont->getParent();
- else
- xRef = uno::Reference< awt::XWindowPeer >();
- }
-
- return xTop;
-}
-#endif
-
}
#include "bin.hxx"
@@ -142,13 +122,7 @@ uno::Reference <awt::XLayoutConstrains> WidgetFactory::toolkitCreateWidget (uno:
{
desc.Type = awt::WindowClass_SIMPLE;
-#if 0
- // top container -- a wrapper for framewindow -- is de-coupled
- // from awt::XWindowPeer. So, getParent() fails at it.
- uno::Reference< awt::XWindowPeer > xWinParent = getParent( xParent );
-#else
uno::Reference< awt::XWindowPeer > xWinParent( xParent, uno::UNO_QUERY );
-#endif
assert( xParent.is() );
assert( xWinParent.is() );
/*
@@ -197,18 +171,6 @@ uno::Reference <awt::XLayoutConstrains> WidgetFactory::toolkitCreateWidget (uno:
return uno::Reference< awt::XLayoutConstrains >();
}
-#if 0 // This shadows the show="false" property and seems otherwise
- // unnecessary
-
- // default to visible, let then people change it on properties
- if ( ! bToplevel )
- {
- uno::Reference< awt::XWindow> xWindow( xPeer, uno::UNO_QUERY );
- if ( xWindow.is() )
- xWindow->setVisible( true );
- }
-#endif
-
return xPeer;
}
@@ -325,25 +287,6 @@ PropHelper::getFastPropertyValue( uno::Any& rValue,
{
OSL_ASSERT( nHandle >= 0 && nHandle < (sal_Int32) maDetails.size() );
const PropDetails &rInfo = maDetails[ nHandle ];
-#if 0
- switch ( rInfo.aType.getTypeClass() )
- {
-#define MAP(classtype,ctype) \
- case uno::TypeClass_##classtype: \
- rValue <<= *(ctype *)(rInfo.pValue); \
- break
- MAP( DOUBLE, double );
- MAP( SHORT, sal_Int16 );
- MAP( LONG, sal_Int32 );
- MAP( UNSIGNED_SHORT, sal_uInt16 );
- MAP( UNSIGNED_LONG, sal_uInt32 );
- MAP( STRING, ::rtl::OUString );
- default:
- DBG_ERROR( "ERROR: unknown type to map!" );
- break;
- }
-#undef MAP
-#endif
rValue.setValue( rInfo.pValue, rInfo.aType );
}
@@ -598,14 +541,9 @@ Window* WidgetFactory::layoutCreateWindow (VCLXWindow** component, Window *paren
}
else if ( name.equalsAscii( "tabpage" ) )
{
-#if 0
- if ( !parent )
- parent = layout::TabPage::global_parent;
-#else
if (layout::TabPage::global_parent)
parent = layout::TabPage::global_parent;
layout::TabPage::global_parent = 0;
-#endif
//window = new TabPage( parent, ImplGetWinBits( attributes, 0 ) );
attributes ^= awt::WindowAttribute::SHOW;
WinBits nStyle = ImplGetWinBits( attributes, 0 );
@@ -629,13 +567,6 @@ Window* WidgetFactory::layoutCreateWindow (VCLXWindow** component, Window *paren
window = new Window( parent, ImplGetWinBits( attributes, 0 ) );
*component = new layoutimpl::LocalizedString();
}
-#if 0 // parent paranoia
- else if ( name.equalsAscii( "listbox" ) )
- {
- window = new ListBox (parent, ImplGetWinBits (attributes, 0));
- *component = new VCLXListBox ();
- }
-#endif
else if (name.equalsAscii ("svxfontlistbox")
|| name.equalsAscii ("svxlanguagebox"))
{
diff --git a/toolkit/source/layout/core/import.hxx b/toolkit/source/layout/core/import.hxx
index 0b49c559dd92..2eea1b0975ee 100644
--- a/toolkit/source/layout/core/import.hxx
+++ b/toolkit/source/layout/core/import.hxx
@@ -89,54 +89,6 @@ private:
RadioGroupsMap mxRadioGroups;
};
-#if 0
-// generator
-class Widget
-{
-public:
- Widget( css::uno::Reference< css::awt::XToolkit > xToolkit,
- css::uno::Reference< css::awt::XWindow > xToplevel,
- rtl::OUString unoName, long attrbs );
- virtual ~Widget();
-
- virtual void setProperties( const PropList &rProps );
-
- virtual bool addChild( Widget *pChild );
- virtual void setChildProperties( Widget *pChild, const PropList &rProps );
-
- inline css::uno::Reference< css::awt::XLayoutConstrains > getPeer()
- { return mxWidget; }
-
- inline css::uno::Reference< css::awt::XLayoutConstrains > getContainer()
- { return mxContainer; }
-
-protected:
- css::uno::Reference< css::awt::XLayoutConstrains > mxWidget;
- css::uno::Reference< css::awt::XLayoutContainer > mxContainer;
-};
-
-class Root
-{
-public:
- Root( css::uno::Reference< css::awt::XToolkit > xToolkit )
- : mxToolkit( xToolkit ) {}
- ~Root();
-
- virtual Widget *create( rtl::OUString id, const rtl::OUString unoName, long attrbs );
-
- css::uno::Reference< css::awt::XLayoutConstrains > getById( rtl::OUString id );
- inline css::uno::Reference< css::awt::XLayoutConstrains > getToplevel();
-
-protected:
- css::uno::Reference< css::awt::XToolkit > mxToolkit;
- Widget *mpToplevel;
-
- typedef std::hash_map< rtl::OUString, css::uno::Reference< css::awt::XLayoutConstrains >,
- rtl::OUStringHash > ItemHash;
- ItemHash maItems;
-};
-#endif
-
// parser
class ImportContext : public ::cppu::WeakImplHelper1< css::xml::input::XRoot >
{
diff --git a/toolkit/source/layout/core/proplist.cxx b/toolkit/source/layout/core/proplist.cxx
index d1b6a9b9f4ea..24c9bc471833 100644
--- a/toolkit/source/layout/core/proplist.cxx
+++ b/toolkit/source/layout/core/proplist.cxx
@@ -349,31 +349,6 @@ static const AttributesMap attribsMap[] =
};
static const int attribsMapLen = sizeof( attribsMap ) / sizeof( AttributesMap );
-#if 0
-long getAttribute( const OUString &rName, bool bTopWindow )
-{
-
- int min = 0, max = attribsMapLen - 1, mid, cmp;
- do
- {
- mid = min +( max - min )/2;
- cmp = rName.compareToAscii( attribsMap[ mid ].name );
- if ( cmp > 0 )
- min = mid+1;
- else if ( cmp < 0 )
- max = mid-1;
- else
- {
- if ( bTopWindow || attribsMap[ mid ].value )
- return attribsMap[ mid ].windowAttr;
- return 0;
- }
- }
- while ( min <= max );
- return 0;
-}
-#endif
-
void propsFromAttributes( const uno::Reference<xml::input::XAttributes> & xAttributes,
PropList &rProps, sal_Int32 nNamespace )
{
diff --git a/toolkit/source/layout/core/root.cxx b/toolkit/source/layout/core/root.cxx
index b360595aebec..f5b96d94d5ae 100644
--- a/toolkit/source/layout/core/root.cxx
+++ b/toolkit/source/layout/core/root.cxx
@@ -330,24 +330,6 @@ LayoutWidget *LayoutRoot::create( OUString id, const OUString unoName, long attr
return pWidget;
}
-#if 0
-uno::Reference< awt::XLayoutConstrains > LayoutRoot::getToplevel()
-{
- if ( mpToplevel )
- return mpToplevel->getPeer();
- return uno::Reference< awt::XLayoutConstrains > ();
-}
-
-uno::Reference< awt::XLayoutConstrains > LayoutRoot::getById( OUString id )
-{
- uno::Reference< awt::XLayoutConstrains > rRef = 0;
- ItemHash::iterator it = maItems.find( id );
- if ( it != maItems.end() )
- rRef = it->second;
- return rRef;
-}
-#endif
-
LayoutWidget::LayoutWidget( uno::Reference< awt::XToolkit > xToolkit,
uno::Reference< awt::XLayoutContainer > xParent,
OUString unoName, long attrbs )
diff --git a/toolkit/source/layout/vcl/wrapper.cxx b/toolkit/source/layout/vcl/wrapper.cxx
index 9b210925f25c..3acb946f7545 100644
--- a/toolkit/source/layout/vcl/wrapper.cxx
+++ b/toolkit/source/layout/vcl/wrapper.cxx
@@ -1126,25 +1126,6 @@ void TabControl::InsertPage (sal_uInt16 id, OUString const& title, sal_uInt16 po
#else
GetTabPage (id)->SetText (title);
#endif
-
-#if 0
- /// This so seems the right solution, but it makes the buttons of the
- /// tabdialog move up
-
- ::TabPage *page = GetTabPage (id);
- if (Window *w = dynamic_cast <Window*> (page))
- {
- w->SetParent (this);
- //GetVCLXTabControl ()->Box_Base::addChild (uno::Reference <awt::XLayoutConstrains> (w->GetPeer (), uno::UNO_QUERY));
- //GetVCLXTabControl ()->Box_Base::AddChild (uno::Reference <awt::XLayoutConstrains> (w->GetPeer (), uno::UNO_QUERY));
- //GetVCLXTabControl ()->AddChild (w);
- //GetVCLXTabControl ()->AddChild (uno::Reference <awt::XLayoutConstrains> (w->GetPeer (), uno::UNO_QUERY));
- //uno::Reference <uno::XInterface> x (page->GetWindowPeer());
- //GetVCLXTabControl ()->AddChild (uno::Reference <awt::XLayoutConstrains> (page->::Window::GetWindowPeer (), uno::UNO_QUERY));
- //GetVCLXTabControl ()->AddChild (uno::Reference <awt::XLayoutConstrains> (page->GetComponentInterface (), uno::UNO_QUERY));
- }
- getImpl ().redraw ();
-#endif
}
void TabControl::RemovePage (sal_uInt16 id)
{
@@ -1175,21 +1156,6 @@ sal_uInt16 TabControl::GetCurPageId () const
void TabControl::SetTabPage (sal_uInt16 id, ::TabPage* page)
{
GetTabControl ()->SetTabPage (id, page);
-
-#if 0
- /// This so seems the right solution, but it makes the buttons of the
- /// tabdialog move up
- if (Window *w = dynamic_cast <Window*> (page))
- {
- w->SetParent (this);
- //GetVCLXTabControl ()->Box_Base::addChild (uno::Reference <awt::XLayoutConstrains> (w->GetPeer (), uno::UNO_QUERY));
- //GetVCLXTabControl ()->Box_Base::AddChild (uno::Reference <awt::XLayoutConstrains> (w->GetPeer (), uno::UNO_QUERY));
- //GetVCLXTabControl ()->AddChild (w);
- //GetVCLXTabControl ()->AddChild (uno::Reference <awt::XLayoutConstrains> (w->GetPeer (), uno::UNO_QUERY));
- //GetVCLXTabControl ()->AddChild (uno::Reference <awt::XLayoutConstrains> (page->GetWindowPeer (), uno::UNO_QUERY));
- //GetVCLXTabControl ()->AddChild (uno::Reference <awt::XLayoutConstrains> (page->GetComponentInterface (), uno::UNO_QUERY));
- }
-#endif
getImpl ().redraw ();
}
::TabPage* TabControl::GetTabPage (sal_uInt16 id) const
@@ -1223,17 +1189,6 @@ void TabControl::SetTabPageSizePixel (Size const& size)
}
Size TabControl::GetTabPageSizePixel () const
{
-#if 0
- //return GetTabControl ()->GetTabPageSizePixel ();
- static size_t const tab_page_first_index = 1;
- for (size_t i = 0; i < GetPageCount (); i++)
- {
- ::TabPage *p = GetTabPage (i + tab_page_first_index);
- //if (dynamic_cast<Windowt*> (p))
- if (i) // URG
- return p->GetOptimalSize (WINDOWSIZE_MINIMUM);
- }
-#endif
return GetTabControl ()->GetTabPageSizePixel ();
}
@@ -1391,10 +1346,6 @@ public:
{
DBG_ERROR( "ERROR: failed to load image: `%s'" /*, pName*/ );
}
-#if 0
- else
- getImpl().mxGraphic->...();
-#endif
}
};
@@ -1410,20 +1361,6 @@ void FixedImage::setImage( ::Image const& i )
//getImpl().mxGraphic =
}
-#if 0
-
-FixedImage::FixedImage( const char *pName )
- : pImpl( new FixedImageImpl( pName ) )
-{
-}
-
-FixedImage::~FixedImage()
-{
- delete pImpl;
-}
-
-#endif
-
IMPL_CONSTRUCTORS( ProgressBar, Control, "ProgressBar" );
IMPL_GET_IMPL( ProgressBar );
diff --git a/toolkit/workben/layout/editor.cxx b/toolkit/workben/layout/editor.cxx
index 852b17b68a1c..f93731ab9c0a 100644
--- a/toolkit/workben/layout/editor.cxx
+++ b/toolkit/workben/layout/editor.cxx
@@ -161,19 +161,6 @@ public:
mxContainer = uno::Reference< awt::XLayoutContainer >( mxWidget, uno::UNO_QUERY );
mrLabel = rtl::OUString( label, strlen( label ), RTL_TEXTENCODING_UTF8 );
-
-#if 0 /* obsolete */
- // FIXME: this code is meant to import a XML file. Just use the importer,
- // then pass the root widget. But information like the ID string is lost.
- // So, this needs to be more closely tight to the importer.
- uno::Sequence< uno::Reference< awt::XLayoutConstrains > > aChildren;
- for ( int i = 0; i < aChildren.getLength(); i++ )
- {
- Widget *pChild = new Widget( aChildren[ i ], "---" );
- maChildren.push_back( pChild );
- pChild->mpParent = this;
- }
-#endif
}
Widget( rtl::OUString id, uno::Reference< awt::XToolkit > xToolkit,
@@ -205,17 +192,7 @@ public:
// set default Text property
// TODO: disable editing of text fields, check boxes selected, etc...
-#if 0
- uno::Reference< awt::XVclWindowPeer> xVclPeer( mxWidget, uno::UNO_QUERY )
- if ( xVclPeer.is() ) // XVclWindowPeer ignores missing / incorrect properties
-
-//FIXME: it looks odd on widgets like NumericField seeing text which is deleted
-// when you interact with it... We can avoid it for those widgets, by doing a getProp
-// of "Text" and check if it is empty or not.
- xVclPeer->setProperty( rtl::OUString::createFromAscii( "Text" ),
- uno::makeAny( rtl::OUString::createFromAscii( "new widget" ) ) );
-#endif
// store original properties
{
@@ -685,11 +662,6 @@ bool moveWidget( Widget *pWidget, bool up /*or down*/ )
}
else
{
-// TODO: this is a nice feature, but we probably want to do it explicitely...
-#if 0
- if ( pWidget->down() && pWidget->swapWithChild( pWidget->down() ) )
- return true;
-#endif
}
}
@@ -893,66 +865,14 @@ class PropertiesList : public layout::Table
mbMultiLine = bMultiLine;
}
-#if 0
- // TODO: make this global... We'll likely need it for export...
- struct Translate {
- const char *ori, *dest;
- };
- static rtl::OUString stringReplace( rtl::OUString _str,
- Translate *trans )
- {
- const sal_Unicode *str = _str.getStr();
- rtl::OUStringBuffer buf;
- int i, j, k;
- for ( i = 0; i < _str.getLength(); i++ )
- {
- for ( j = 0; trans[ j ].ori; j++ )
- {
- const char *ori = trans[ j ].ori;
- for ( k = 0; ori[ k ] && i+k < _str.getLength(); k++ )
- if ( ori[ k ] != str[ i+k ] )
- break;
- if ( !ori[ k ] )
- {
- // found substring
- buf.appendAscii( trans[ j ].dest );
- i += k;
- continue;
- }
- }
- buf.append( str[ i ] );
- }
- return buf.makeStringAndClear();
- }
-#endif
-
virtual void load()
{
-#if 0
- // replace end of lines by "\\n" strings
- Translate trans[] = {
- { "\\", "\\\\" }, { "\n", "\\n" }, { 0, 0 }
- };
- rtl::OUString str = anyToString( getValue() );
- str = stringReplace( str, trans );
- SetText( str );
-#endif
mpEdit->SetText( getValue() );
checkProperty();
}
virtual void store()
{
-#if 0
- // replace "\\n" strings by actual end of lines
- Translate trans[] = {
- { "\\\\", "\\" }, { "\\n", "\n" },
- { "\\", "" }, { 0, 0 }
- };
- rtl::OUString str = GetText();
- str = stringReplace( str, trans );
- save( uno::makeAny( str ) );
-#endif
save( uno::makeAny( (rtl::OUString) mpEdit->GetText() ) );
}
};
@@ -1210,20 +1130,6 @@ class PropertiesList : public layout::Table
"Printable", "Repeat", "RepeatDelay", "Tabstop"
};
-#if 0
- // checks list sanity -- enable this when you add some entries...
- for ( unsigned int i = 1; i < sizeof( toIgnoreList )/sizeof( char * ); i++ )
- {
- if ( strcmp(toIgnoreList[i-1], toIgnoreList[i]) >= 0 )
- {
- printf("ignore list not ordered properly: "
- "'%s' should come before '%s'\n",
- toIgnoreList[i], toIgnoreList[i-1]);
- exit(-1);
- }
- }
-#endif
-
int min = 0, max = sizeof( toIgnoreList )/sizeof( char * ) - 1, mid, cmp;
do {
mid = min + (max - min)/2;
diff --git a/toolkit/workben/layout/zoom.cxx b/toolkit/workben/layout/zoom.cxx
index 3f19089761e1..0fa756a33f03 100644
--- a/toolkit/workben/layout/zoom.cxx
+++ b/toolkit/workben/layout/zoom.cxx
@@ -92,16 +92,6 @@ struct SvxViewLayoutItem : public LAYOUT_SfxPoolItem
void SetBookMode( bool )
{
}
-#if 0 // needed for real SfxPoolItem
- int operator==( const SfxPoolItem& ) const
- {
- return 0;
- }
- SfxPoolItem* Clone( SfxItemPool* ) const
- {
- return 0;
- }
-#endif
};
#else /* !TEST_LAYOUT */
#include <svx/zoomitem.hxx>