diff options
109 files changed, 586 insertions, 586 deletions
diff --git a/odk/examples/CLI/CSharp/Spreadsheet/GeneralTableSample.cs b/odk/examples/CLI/CSharp/Spreadsheet/GeneralTableSample.cs index 7a3c50e2289d..70942f737e64 100644 --- a/odk/examples/CLI/CSharp/Spreadsheet/GeneralTableSample.cs +++ b/odk/examples/CLI/CSharp/Spreadsheet/GeneralTableSample.cs @@ -42,13 +42,13 @@ public class GeneralTableSample : SpreadsheetDocHelper } } -// ________________________________________________________________ + public GeneralTableSample( String[] args ) : base( args ) { } -// ________________________________________________________________ + /// This sample function modifies cells and cell ranges. public void doSampleFunction() diff --git a/odk/examples/CLI/CSharp/Spreadsheet/SpreadsheetDocHelper.cs b/odk/examples/CLI/CSharp/Spreadsheet/SpreadsheetDocHelper.cs index 427189f12257..d8ddd6beb9cf 100644 --- a/odk/examples/CLI/CSharp/Spreadsheet/SpreadsheetDocHelper.cs +++ b/odk/examples/CLI/CSharp/Spreadsheet/SpreadsheetDocHelper.cs @@ -39,7 +39,7 @@ public class SpreadsheetDocHelper : System.IDisposable private unoidl.com.sun.star.lang.XMultiServiceFactory mxMSFactory; private unoidl.com.sun.star.sheet.XSpreadsheetDocument mxDocument; -// ________________________________________________________________ + public SpreadsheetDocHelper( String[] args ) { @@ -103,7 +103,7 @@ public class SpreadsheetDocHelper : System.IDisposable return xSheet; } -// ________________________________________________________________ + // Methods to fill values into cells. /** Writes a double value into a spreadsheet. @@ -223,7 +223,7 @@ public class SpreadsheetDocHelper : System.IDisposable new uno.Any( (Single) unoidl.com.sun.star.awt.FontWeight.BOLD ) ); } -// ________________________________________________________________ + // Methods to create cell addresses and range addresses. /** Creates a unoidl.com.sun.star.table.CellAddress and initializes it @@ -253,7 +253,7 @@ public class SpreadsheetDocHelper : System.IDisposable return xAddr.getRangeAddress(); } -// ________________________________________________________________ + // Methods to convert cell addresses and range addresses to strings. /** Returns the text address of the cell. @@ -326,7 +326,7 @@ public class SpreadsheetDocHelper : System.IDisposable return aStr; } -// ________________________________________________________________ + /** Connect to a running office that is accepting connections. @return The ServiceManager to instantiate office components. */ @@ -357,5 +357,5 @@ public class SpreadsheetDocHelper : System.IDisposable return (unoidl.com.sun.star.sheet.XSpreadsheetDocument) xComponent; } -// ________________________________________________________________ + } diff --git a/odk/examples/CLI/CSharp/Spreadsheet/SpreadsheetSample.cs b/odk/examples/CLI/CSharp/Spreadsheet/SpreadsheetSample.cs index 2a40a79b5dd2..1dd2f8a03c9c 100644 --- a/odk/examples/CLI/CSharp/Spreadsheet/SpreadsheetSample.cs +++ b/odk/examples/CLI/CSharp/Spreadsheet/SpreadsheetSample.cs @@ -62,7 +62,7 @@ public class SpreadsheetSample : SpreadsheetDocHelper doApplicationSettingsSamples(); } -// ________________________________________________________________ + /** All samples regarding the service com.sun.star.sheet.SheetCell. */ private void doCellSamples() @@ -172,7 +172,7 @@ public class SpreadsheetSample : SpreadsheetDocHelper xAnnotation.setIsVisible( true ); } -// ________________________________________________________________ + /** All samples regarding the service com.sun.star.sheet.SheetCellRange. */ private void doCellRangeSamples() @@ -498,7 +498,7 @@ public class SpreadsheetSample : SpreadsheetDocHelper xSheet.getCellRangeByName( aRange ); } -// ________________________________________________________________ + /** All samples regarding cell range collections. */ private void doCellRangesSamples() @@ -570,7 +570,7 @@ public class SpreadsheetSample : SpreadsheetDocHelper + " resulting list: " + xContainer.getRangeAddressesAsString() ); } -// ________________________________________________________________ + /** All samples regarding cell cursors. */ private void doCellCursorSamples() @@ -606,7 +606,7 @@ public class SpreadsheetSample : SpreadsheetDocHelper "The used area is: " + getCellRangeAddressString( xCursor, true ) ); } -// ________________________________________________________________ + /** All samples regarding the formatting of cells and ranges. */ private void doFormattingSamples() @@ -792,7 +792,7 @@ public class SpreadsheetSample : SpreadsheetDocHelper xEntries ) ); } -// ________________________________________________________________ + /** All samples regarding the spreadsheet document. */ private void doDocumentSamples() @@ -986,7 +986,7 @@ public class SpreadsheetSample : SpreadsheetDocHelper xScenario.apply(); } -// ________________________________________________________________ + private void doNamedRangesSamples() { @@ -1064,7 +1064,7 @@ public class SpreadsheetSample : SpreadsheetDocHelper xSheet.getCellByPosition( 8, 49 ).setFormula( "=Apples+Oranges" ); } -// ________________________________________________________________ + /** Helper for doDatabaseSamples: get name of first database. */ private String getFirstDatabaseName() @@ -1338,7 +1338,7 @@ public class SpreadsheetSample : SpreadsheetDocHelper Console.WriteLine("can't get database"); } -// ________________________________________________________________ + private void doDataPilotSamples() { @@ -1419,7 +1419,7 @@ public class SpreadsheetSample : SpreadsheetDocHelper unoidl.com.sun.star.sheet.GeneralFunction.AVERAGE ) ); } -// ________________________________________________________________ + private void doFunctionAccessSamples() { @@ -1469,7 +1469,7 @@ public class SpreadsheetSample : SpreadsheetDocHelper Console.WriteLine(); } -// ________________________________________________________________ + private void doApplicationSettingsSamples() { @@ -1490,6 +1490,6 @@ public class SpreadsheetSample : SpreadsheetDocHelper Console.WriteLine( aEntries[i] ); } -// ________________________________________________________________ + } diff --git a/odk/examples/CLI/CSharp/Spreadsheet/ViewSample.cs b/odk/examples/CLI/CSharp/Spreadsheet/ViewSample.cs index b2795e02f4d7..b5d0543c1e0c 100644 --- a/odk/examples/CLI/CSharp/Spreadsheet/ViewSample.cs +++ b/odk/examples/CLI/CSharp/Spreadsheet/ViewSample.cs @@ -42,14 +42,14 @@ public class ViewSample : SpreadsheetDocHelper } } -// ________________________________________________________________ + public ViewSample( String[] args ) : base( args ) { } -// ________________________________________________________________ + /** This sample function performs all changes on the view. */ public void doSampleFunction() @@ -135,7 +135,7 @@ public class ViewSample : SpreadsheetDocHelper } } -// ________________________________________________________________ + // listener to react on finished selection @@ -177,6 +177,6 @@ public class ViewSample : SpreadsheetDocHelper } } -// ________________________________________________________________ + } diff --git a/odk/examples/DevelopersGuide/Charts/CalcHelper.java b/odk/examples/DevelopersGuide/Charts/CalcHelper.java index ade201ccd297..5d8a80061181 100644 --- a/odk/examples/DevelopersGuide/Charts/CalcHelper.java +++ b/odk/examples/DevelopersGuide/Charts/CalcHelper.java @@ -70,7 +70,7 @@ public class CalcHelper initSpreadSheet(); } - // ____________________ + public XSpreadsheet getChartSheet() throws RuntimeException { @@ -93,7 +93,7 @@ public class CalcHelper return aSheet; } - // ____________________ + public XSpreadsheet getDataSheet() throws RuntimeException { @@ -119,7 +119,7 @@ public class CalcHelper return aSheet; } - // ____________________ + /** Insert a chart using the given name as name of the OLE object and the range as correspoding range of data to be used for rendering. The chart is placed in the sheet for charts at @@ -197,7 +197,7 @@ public class CalcHelper return aResult; } - // ____________________ + /** Fill a rectangular range with random numbers. The first column has increasing values @@ -263,7 +263,7 @@ public class CalcHelper return aRange; } - // ____________________ + public XCellRange insertFormulaRange( int nColumnCount, int nRowCount ) { @@ -323,7 +323,7 @@ public class CalcHelper return aRange; } - // ____________________ + /** Bring the sheet containing charts visually to the foreground */ @@ -345,7 +345,7 @@ public class CalcHelper private XSpreadsheetDocument maSpreadSheetDoc; - // ____________________ + /** create two sheets, one for data and one for charts in the document */ diff --git a/odk/examples/DevelopersGuide/Charts/ChartInCalc.java b/odk/examples/DevelopersGuide/Charts/ChartInCalc.java index 62042b95b5b7..4192f866a6f2 100644 --- a/odk/examples/DevelopersGuide/Charts/ChartInCalc.java +++ b/odk/examples/DevelopersGuide/Charts/ChartInCalc.java @@ -70,7 +70,7 @@ import com.sun.star.util.MalformedNumberFormatException; public class ChartInCalc { - // ____________________ + public static void main( String args[] ) { @@ -137,7 +137,7 @@ public class ChartInCalc } - // ________________________________________ + public ChartInCalc( XChartDocument aChartDoc ) { @@ -145,7 +145,7 @@ public class ChartInCalc maDiagram = maChartDocument.getDiagram(); } - // ____________________ + public void lockControllers() throws RuntimeException @@ -153,7 +153,7 @@ public class ChartInCalc UnoRuntime.queryInterface( XModel.class, maChartDocument ).lockControllers(); } - // ____________________ + public void unlockControllers() throws RuntimeException @@ -161,7 +161,7 @@ public class ChartInCalc UnoRuntime.queryInterface( XModel.class, maChartDocument ).unlockControllers(); } - // ____________________ + public void testDiagram() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -180,7 +180,7 @@ public class ChartInCalc } } - // ____________________ + public void testDataRowProperties() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -225,7 +225,7 @@ public class ChartInCalc } } - // ____________________ + public void testDataPointProperties() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -271,7 +271,7 @@ public class ChartInCalc } } - // ____________________ + public void testArea() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -287,7 +287,7 @@ public class ChartInCalc } } - // ____________________ + public void testWall() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -301,7 +301,7 @@ public class ChartInCalc aWall.setPropertyValue( "FillColor", new Integer( 0xcccccc )); } - // ____________________ + public void testTitle() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -336,7 +336,7 @@ public class ChartInCalc } } - // ____________________ + public void testAxis() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -376,7 +376,7 @@ public class ChartInCalc } } - // ____________________ + public void testGrid() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -406,10 +406,10 @@ public class ChartInCalc } - // ______________________________ - // + + // private members - // ______________________________ + private XChartDocument maChartDocument; private XDiagram maDiagram; diff --git a/odk/examples/DevelopersGuide/Charts/ChartInDraw.java b/odk/examples/DevelopersGuide/Charts/ChartInDraw.java index f7fbb2cff263..ae1bd973f8be 100644 --- a/odk/examples/DevelopersGuide/Charts/ChartInDraw.java +++ b/odk/examples/DevelopersGuide/Charts/ChartInDraw.java @@ -60,7 +60,7 @@ import com.sun.star.beans.UnknownPropertyException; public class ChartInDraw { - // ____________________ + public static void main( String args[] ) { @@ -108,7 +108,7 @@ public class ChartInDraw } - // ________________________________________ + public ChartInDraw( XChartDocument aChartDoc ) { @@ -116,7 +116,7 @@ public class ChartInDraw maDiagram = maChartDocument.getDiagram(); } - // ____________________ + public void lockControllers() throws RuntimeException @@ -124,7 +124,7 @@ public class ChartInDraw UnoRuntime.queryInterface( XModel.class, maChartDocument ).lockControllers(); } - // ____________________ + public void unlockControllers() throws RuntimeException @@ -132,7 +132,7 @@ public class ChartInDraw UnoRuntime.queryInterface( XModel.class, maChartDocument ).unlockControllers(); } - // ____________________ + public void testArea() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -148,7 +148,7 @@ public class ChartInDraw } } - // ____________________ + public void testWall() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -162,7 +162,7 @@ public class ChartInDraw aWall.setPropertyValue( "FillStyle", FillStyle.SOLID ); } - // ____________________ + public void testTitle() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -183,7 +183,7 @@ public class ChartInDraw } } - // ____________________ + public void testLegend() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -197,7 +197,7 @@ public class ChartInDraw aLegendProp.setPropertyValue( "FillColor", new Integer( 0xeeddee )); } - // ____________________ + public void testThreeD() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -283,10 +283,10 @@ public class ChartInDraw aDiaProp.setPropertyValue( "D3DSceneLightOn1", new Boolean( true )); } - // ______________________________ - // + + // private members - // ______________________________ + private XChartDocument maChartDocument; private XDiagram maDiagram; diff --git a/odk/examples/DevelopersGuide/Charts/ChartInWriter.java b/odk/examples/DevelopersGuide/Charts/ChartInWriter.java index 6506cb92f32e..34678a1eccad 100644 --- a/odk/examples/DevelopersGuide/Charts/ChartInWriter.java +++ b/odk/examples/DevelopersGuide/Charts/ChartInWriter.java @@ -66,7 +66,7 @@ import com.sun.star.beans.UnknownPropertyException; */ public class ChartInWriter { - // ____________________ + public static void main( String args[] ) { @@ -113,7 +113,7 @@ public class ChartInWriter } - // ________________________________________ + public ChartInWriter( XChartDocument aChartDoc ) { @@ -121,7 +121,7 @@ public class ChartInWriter maDiagram = maChartDocument.getDiagram(); } - // ____________________ + public void lockControllers() throws RuntimeException @@ -129,7 +129,7 @@ public class ChartInWriter UnoRuntime.queryInterface( XModel.class, maChartDocument ).lockControllers(); } - // ____________________ + public void unlockControllers() throws RuntimeException @@ -137,7 +137,7 @@ public class ChartInWriter UnoRuntime.queryInterface( XModel.class, maChartDocument ).unlockControllers(); } - // ____________________ + public void testWall() throws RuntimeException, UnknownPropertyException, PropertyVetoException, @@ -151,10 +151,10 @@ public class ChartInWriter aWall.setPropertyValue( "FillStyle", FillStyle.SOLID ); } - // ______________________________ - // + + // private members - // ______________________________ + private XChartDocument maChartDocument; private XDiagram maDiagram; diff --git a/odk/examples/DevelopersGuide/Charts/Helper.java b/odk/examples/DevelopersGuide/Charts/Helper.java index 92ba8c476474..580d5adc4fa4 100644 --- a/odk/examples/DevelopersGuide/Charts/Helper.java +++ b/odk/examples/DevelopersGuide/Charts/Helper.java @@ -71,7 +71,7 @@ public class Helper } } - // ____________________ + public XSpreadsheetDocument createSpreadsheetDocument() { @@ -79,28 +79,28 @@ public class Helper XSpreadsheetDocument.class, createDocument( "scalc" )); } - // ____________________ + public XModel createPresentationDocument() { return createDocument( "simpress" ); } - // ____________________ + public XModel createDrawingDocument() { return createDocument( "sdraw" ); } - // ____________________ + public XModel createTextDocument() { return createDocument( "swriter" ); } - // ____________________ + public XModel createDocument( String sDocType ) { diff --git a/odk/examples/DevelopersGuide/Charts/JavaSampleChartAddIn.java b/odk/examples/DevelopersGuide/Charts/JavaSampleChartAddIn.java index a70481e1631b..c71496547374 100644 --- a/odk/examples/DevelopersGuide/Charts/JavaSampleChartAddIn.java +++ b/odk/examples/DevelopersGuide/Charts/JavaSampleChartAddIn.java @@ -208,7 +208,7 @@ public class JavaSampleChartAddIn extends WeakBase implements } // position lines - // -------------- + // get data XChartDataArray aDataArray = UnoRuntime.queryInterface( diff --git a/odk/examples/DevelopersGuide/Charts/ListenAtCalcRangeInDraw.java b/odk/examples/DevelopersGuide/Charts/ListenAtCalcRangeInDraw.java index 266f07a9c728..c1227b2d2721 100644 --- a/odk/examples/DevelopersGuide/Charts/ListenAtCalcRangeInDraw.java +++ b/odk/examples/DevelopersGuide/Charts/ListenAtCalcRangeInDraw.java @@ -99,7 +99,7 @@ public class ListenAtCalcRangeInDraw implements XChartDataChangeEventListener maChartDocument.attachData( maChartData ); } - // ____________________ + public void run() { @@ -131,7 +131,7 @@ public class ListenAtCalcRangeInDraw implements XChartDataChangeEventListener chartDataChanged( aEvent ); } - // ____________________ + // XEventListener (base of XChartDataChangeEventListener) public void disposing( EventObject aSourceObj ) @@ -154,7 +154,7 @@ public class ListenAtCalcRangeInDraw implements XChartDataChangeEventListener System.exit( 0 ); } - // ____________________ + // XChartDataChangeEventListener public void chartDataChanged( ChartDataChangeEvent aEvent ) diff --git a/odk/examples/DevelopersGuide/Charts/SelectionChangeListener.java b/odk/examples/DevelopersGuide/Charts/SelectionChangeListener.java index d544d03abdf3..98f2dbb2abd7 100644 --- a/odk/examples/DevelopersGuide/Charts/SelectionChangeListener.java +++ b/odk/examples/DevelopersGuide/Charts/SelectionChangeListener.java @@ -107,7 +107,7 @@ public class SelectionChangeListener implements XSelectionChangeListener { "com.sun.star.chart.XYDiagram" ); } - // ____________________ + public void run() { boolean bTrying = true; @@ -138,7 +138,7 @@ public class SelectionChangeListener implements XSelectionChangeListener { } } - // ____________________ + // XEventListener (base of XSelectionChangeListener) public void disposing( EventObject aSourceObj ) { @@ -159,7 +159,7 @@ public class SelectionChangeListener implements XSelectionChangeListener { System.exit( 0 ); } - // ____________________ + // XSelectionChangeListener public void selectionChanged( EventObject aEvent ) { diff --git a/odk/examples/DevelopersGuide/Components/Addons/JobsAddon/AsyncJob.java b/odk/examples/DevelopersGuide/Components/Addons/JobsAddon/AsyncJob.java index d0ffaafebaa7..1070ffcb0c78 100644 --- a/odk/examples/DevelopersGuide/Components/Addons/JobsAddon/AsyncJob.java +++ b/odk/examples/DevelopersGuide/Components/Addons/JobsAddon/AsyncJob.java @@ -60,7 +60,7 @@ public class AsyncJob extends WeakBase implements XServiceInfo, XAsyncJob */ public static final java.lang.String IMPLEMENTATIONNAME = "com.sun.star.comp.framework.java.services.AsyncJob"; - //___________________________________________ + // interface /** initialize a new instance of this class with default values. */ @@ -69,7 +69,7 @@ public class AsyncJob extends WeakBase implements XServiceInfo, XAsyncJob m_xCmpCtx = xCompContext; } - //___________________________________________ + /** starts execution of this job. * @@ -222,7 +222,7 @@ public class AsyncJob extends WeakBase implements XServiceInfo, XAsyncJob xListener.jobFinished(this, lReturn); } - //___________________________________________ + /** show an info box with the UNO based toolkit. * @@ -292,7 +292,7 @@ public class AsyncJob extends WeakBase implements XServiceInfo, XAsyncJob } } - //___________________________________________ + private void showInfoNonModal( java.lang.String sTitle , java.lang.String sMessage ) @@ -319,7 +319,7 @@ public class AsyncJob extends WeakBase implements XServiceInfo, XAsyncJob }.start(); } - //___________________________________________ + /** helper to print out the given argument list. * @@ -407,7 +407,7 @@ public class AsyncJob extends WeakBase implements XServiceInfo, XAsyncJob } - //___________________________________________ + public synchronized static com.sun.star.lang.XSingleComponentFactory __getComponentFactory(java.lang.String sImplName) { @@ -418,7 +418,7 @@ public class AsyncJob extends WeakBase implements XServiceInfo, XAsyncJob return xFactory; } - //___________________________________________ + // This method not longer necessary since OOo 3.4 where the component registration // was changed to passive component registration. For more details see // http://wiki.openoffice.org/wiki/Passive_Component_Registration diff --git a/odk/examples/DevelopersGuide/Components/Addons/ProtocolHandlerAddon_cpp/component.cxx b/odk/examples/DevelopersGuide/Components/Addons/ProtocolHandlerAddon_cpp/component.cxx index 5456af87ee22..6233fb7c2913 100644 --- a/odk/examples/DevelopersGuide/Components/Addons/ProtocolHandlerAddon_cpp/component.cxx +++ b/odk/examples/DevelopersGuide/Components/Addons/ProtocolHandlerAddon_cpp/component.cxx @@ -53,9 +53,9 @@ using namespace ::com::sun::star::uno; using namespace ::com::sun::star::lang; using namespace ::com::sun::star::registry; -//################################################################################################## + //#### EXPORTED #################################################################################### -//################################################################################################## + /** * This function is called to get service factories for an implementation. diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SConnection.hxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SConnection.hxx index 8072094d7346..9aa70405ee60 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SConnection.hxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SConnection.hxx @@ -77,9 +77,9 @@ namespace connectivity protected: rtl_TextEncoding m_nTextEncoding; // the encoding which is used for all text conversions - //==================================================================== + // Data attributes - //==================================================================== + TTypeInfoVector m_aTypeInfo; // vector containing an entry // for each row returned by // DatabaseMetaData.getTypeInfo. @@ -142,7 +142,7 @@ namespace connectivity // XWarningsSupplier virtual ::com::sun::star::uno::Any SAL_CALL getWarnings( ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException); virtual void SAL_CALL clearWarnings( ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException); - // + // should we use the catalog on filebased databases inline sal_Bool isCatalogUsed() const { return m_bUseCatalog; } diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDatabaseMetaData.hxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDatabaseMetaData.hxx index bdd3ac439796..f7d294871700 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDatabaseMetaData.hxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDatabaseMetaData.hxx @@ -44,9 +44,9 @@ namespace connectivity { namespace skeleton { - //************************************************************** + //************ Class: ODatabaseMetaData - //************************************************************** + typedef ::cppu::WeakImplHelper1< ::com::sun::star::sdbc::XDatabaseMetaData> ODatabaseMetaData_BASE; diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDriver.cxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDriver.cxx index 4134c83aff47..8cf29445361b 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDriver.cxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDriver.cxx @@ -144,12 +144,12 @@ sal_Int32 SAL_CALL SkeletonDriver::getMinorVersion( ) throw(RuntimeException) } -//......................................................................... + namespace connectivity { namespace skeleton { -//......................................................................... + void release(oslInterlockedCount& _refCount, ::cppu::OBroadcastHelper& rBHelper, @@ -194,9 +194,9 @@ void checkDisposed(sal_Bool _bThrow) throw ( DisposedException ) throw DisposedException(); } -//......................................................................... + } } -//......................................................................... + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SPreparedStatement.hxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SPreparedStatement.hxx index 315d781d40fb..0914e5c5f76d 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SPreparedStatement.hxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SPreparedStatement.hxx @@ -71,9 +71,9 @@ namespace connectivity }; ::std::vector< Parameter> m_aParameters; - //==================================================================== + // Data attributes - //==================================================================== + TTypeInfoVector m_aTypeInfo; // Hashtable containing an entry // for each row returned by // DatabaseMetaData.getTypeInfo. diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SResultSetMetaData.hxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SResultSetMetaData.hxx index 7ce5fd56fa14..1c78c6e032cb 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SResultSetMetaData.hxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SResultSetMetaData.hxx @@ -44,9 +44,9 @@ namespace connectivity { namespace skeleton { - //************************************************************** + //************ Class: ResultSetMetaData - //************************************************************** + typedef ::cppu::WeakImplHelper1< ::com::sun::star::sdbc::XResultSetMetaData> OResultSetMetaData_BASE; class OResultSetMetaData : public OResultSetMetaData_BASE diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SServices.cxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SServices.cxx index 83c3870bae5f..b3ccf08216bd 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SServices.cxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SServices.cxx @@ -56,11 +56,11 @@ typedef Reference< XSingleServiceFactory > (SAL_CALL *createFactoryFunc) rtl_ModuleCount* ); -//*************************************************************************************** -// + + // The required C-Api must be provided! // It contains of 3 special functions that have to be exported. -// + void REGISTER_PROVIDER( diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SStatement.hxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SStatement.hxx index 942d43fef216..1e3d06c82358 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SStatement.hxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SStatement.hxx @@ -60,10 +60,10 @@ namespace connectivity ::com::sun::star::sdbc::XCloseable, ::com::sun::star::sdbc::XMultipleResults> OStatement_BASE; - //************************************************************** + //************ Class: OStatement_Base // is a base class for the normal statement and for the prepared statement - //************************************************************** + class OStatement_Base : public OBase_Mutex, public OStatement_BASE, public ::cppu::OPropertySetHelper, diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/propertyids.cxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/propertyids.cxx index 9b69be270c2e..e71ed7924474 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/propertyids.cxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/propertyids.cxx @@ -90,9 +90,9 @@ namespace skeleton const sal_Char* getPROPERTY_AUTOINCREMENTCREATION() { return "AutoIncrementCreation"; } const sal_Char* getPROPERTY_PRIVILEGES() { return "Privileges"; } - //============================================================ + //= error messages - //============================================================ + const sal_Char* getERRORMSG_SEQUENCE() { return "Function sequence error"; } const sal_Char* getSQLSTATE_SEQUENCE() { return "HY010"; } const sal_Char* getSQLSTATE_GENERAL() { return "HY0000"; } diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/propertyids.hxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/propertyids.hxx index 95b9275954c9..71c2b35dffec 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/propertyids.hxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/propertyids.hxx @@ -83,16 +83,16 @@ namespace skeleton } -//------------------------------------------------------------------------------ + #define DECL_PROP1IMPL(varname, type) \ pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_##varname), PROPERTY_ID_##varname, ::cppu::UnoType< type >::get(), -//------------------------------------------------------------------------------ + #define DECL_PROP0(varname, type) \ DECL_PROP1IMPL(varname, type) 0) -//------------------------------------------------------------------------------ + #define DECL_BOOL_PROP1IMPL(varname) \ pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_##varname), PROPERTY_ID_##varname, ::getBooleanCppuType(), -//------------------------------------------------------------------------------ + #define DECL_BOOL_PROP0(varname) \ DECL_BOOL_PROP1IMPL(varname) 0) diff --git a/odk/examples/DevelopersGuide/Database/sdbcx.java b/odk/examples/DevelopersGuide/Database/sdbcx.java index 696857b0344e..32c434273a38 100644 --- a/odk/examples/DevelopersGuide/Database/sdbcx.java +++ b/odk/examples/DevelopersGuide/Database/sdbcx.java @@ -123,7 +123,7 @@ public class sdbcx new com.sun.star.beans.PropertyValue("user",0,"test1",com.sun.star.beans.PropertyState.DIRECT_VALUE), new com.sun.star.beans.PropertyValue("password",0,"test1",com.sun.star.beans.PropertyState.DIRECT_VALUE) }; - // + // now create a connection to adabas con = xDriver.connect(adabasURL,adabasProps); @@ -172,10 +172,10 @@ public class sdbcx } } - //########################################################### + // 15. example // print all columns of a XColumnsSupplier - //########################################################### + public static void printColumns(XColumnsSupplier xColumnsSup) throws com.sun.star.uno.Exception,SQLException { System.out.println("Example printColumns"); @@ -186,10 +186,10 @@ public class sdbcx for ( int i =0; i<= aColumnNames.length-1; i++) System.out.println(" " + aColumnNames[i]); } - //########################################################### + // 16. example // print all keys inclusive the columns of a key - //########################################################### + public static void printKeys(XColumnsSupplier xColumnsSup) throws com.sun.star.uno.Exception,SQLException { System.out.println("Example printKeys"); @@ -208,10 +208,10 @@ public class sdbcx } } } - //########################################################### + // 17. example // print all keys inclusive the columns of a key - //########################################################### + public static void printIndexes(XColumnsSupplier xColumnsSup) throws com.sun.star.uno.Exception,SQLException { System.out.println("Example printIndexes"); @@ -231,10 +231,10 @@ public class sdbcx } } - //########################################################### + // 18. example // column properties - //########################################################### + public static void printColumnProperties(Object column) throws com.sun.star.uno.Exception,SQLException { System.out.println("Example printColumnProperties"); @@ -256,10 +256,10 @@ public class sdbcx System.out.println("DefaultValue: " + xProp.getPropertyValue("DefaultValue")); } - //########################################################### + // 19. example // index properties - //########################################################### + public static void printIndexProperties(Object index) throws com.sun.star.uno.Exception,SQLException { System.out.println("Example printIndexProperties"); @@ -271,10 +271,10 @@ public class sdbcx System.out.println("IsClustered: " + xProp.getPropertyValue("IsClustered")); } - //########################################################### + // 20. example // key properties - //########################################################### + public static void printKeyProperties(Object key) throws com.sun.star.uno.Exception,SQLException { System.out.println("Example printKeyProperties"); @@ -286,10 +286,10 @@ public class sdbcx System.out.println("DeleteRule: " + xProp.getPropertyValue("DeleteRule")); } - //########################################################### + // 21. example // print all groups and the users with their privileges who belong to this group - //########################################################### + public static void printGroups(XTablesSupplier xTabSup) throws com.sun.star.uno.Exception,SQLException { System.out.println("Example printGroups"); @@ -320,10 +320,10 @@ public class sdbcx } } - //########################################################### + // 22. example // create the table salesmen - //########################################################### + public static void createTableSalesMen(XNameAccess xTables) throws com.sun.star.uno.Exception,SQLException { System.out.println("Example createTableSalesMen"); @@ -395,10 +395,10 @@ public class sdbcx } } - //########################################################### + // 23. example // create a user - //########################################################### + public static void createUser(XNameAccess xUsers) throws com.sun.star.uno.Exception,SQLException { System.out.println("Example createUser"); diff --git a/odk/examples/DevelopersGuide/Drawing/ShapeHelper.java b/odk/examples/DevelopersGuide/Drawing/ShapeHelper.java index 6f1d4aff680c..a16bb2e9e798 100644 --- a/odk/examples/DevelopersGuide/Drawing/ShapeHelper.java +++ b/odk/examples/DevelopersGuide/Drawing/ShapeHelper.java @@ -59,7 +59,7 @@ import com.sun.star.text.XTextRange; public class ShapeHelper { // __________ static helper methods __________ - // + public static XPropertySet createAndInsertShape( XComponent xDrawDoc, XShapes xShapes, Point aPos, Size aSize, String sShapeType ) throws java.lang.Exception diff --git a/odk/examples/DevelopersGuide/Forms/DataAwareness.java b/odk/examples/DevelopersGuide/Forms/DataAwareness.java index 70323e25a373..b11098698700 100644 --- a/odk/examples/DevelopersGuide/Forms/DataAwareness.java +++ b/odk/examples/DevelopersGuide/Forms/DataAwareness.java @@ -690,7 +690,7 @@ public class DataAwareness extends DocumentBasedExample implements XPropertyChan // ensure that we have the tables needed for our example ensureTables(); - // -------------------------------------------------------------- + /* create some shapes */ XPropertySet xSNRField = m_formLayer.insertControlLine( "NumericField", "SNR", "", 3 ); m_formLayer.insertControlLine( "TextField", "FIRSTNAME", "", 11); @@ -704,7 +704,7 @@ public class DataAwareness extends DocumentBasedExample implements XPropertyChan xSNRField.setPropertyValue( "DecimalAccuracy", new Short( (short)0 ) ); xZipField.setPropertyValue( "DecimalAccuracy", new Short( (short)0 ) ); - // -------------------------------------------------------------- + /** need the form the control models belong to for this, we simply obtain the parent for any of the control models we have @@ -720,7 +720,7 @@ public class DataAwareness extends DocumentBasedExample implements XPropertyChan m_xMasterForm.setPropertyValue( "CommandType", new Integer( CommandType.TABLE ) ); m_xMasterForm.setPropertyValue( "Command", "SALESMEN" ); - // -------------------------------------------------------------- + // insert the buttons // create our button operator, if necessary m_aOperator = new ButtonOperator( m_xCtx, m_document, m_xMasterForm ); @@ -732,7 +732,7 @@ public class DataAwareness extends DocumentBasedExample implements XPropertyChan createButton( 42, 63, 8, "new", ">*", FormFeature.MoveToInsertRow ); createButton( 58, 63, 13, "reload", "reload", FormFeature.ReloadForm ); - // -------------------------------------------------------------- + // create a sub for for the sales // for this, first create a sub form and bind it to the SALES table @@ -786,7 +786,7 @@ public class DataAwareness extends DocumentBasedExample implements XPropertyChan xFormReset.addResetListener( this ); - // -------------------------------------------------------------- + // the option for filtering the sales form XIndexContainer xSalesFilterForm = m_document.createSiblingForm( xSalesForm, "SalesFilter" ); XPropertySet xSFFProps = UNO.queryPropertySet( xSalesFilterForm ); @@ -806,7 +806,7 @@ public class DataAwareness extends DocumentBasedExample implements XPropertyChan xManualFilter, xApplyFilter ); - // -------------------------------------------------------------- + // the options section // for this, we need a form which is a sibling of our master form (don't want to interfere // the controls which represent options only with the controls which are used for data access) @@ -858,7 +858,7 @@ public class DataAwareness extends DocumentBasedExample implements XPropertyChan // initally, we want to generate keys when moving to a new record xKeyGen.setPropertyValue( "DefaultState", new Short( (short)1 ) ); - // -------------------------------------------------------------- + // second options block xLabel = m_formLayer.createControlAndShape( "GroupBox", 103, 33, 56, 25, xOptionsForm ); xLabel.setPropertyValue( "Name", "Misc" ); diff --git a/odk/examples/DevelopersGuide/Forms/DocumentBasedExample.java b/odk/examples/DevelopersGuide/Forms/DocumentBasedExample.java index 456e4125c9d2..04a4dbc26199 100644 --- a/odk/examples/DevelopersGuide/Forms/DocumentBasedExample.java +++ b/odk/examples/DevelopersGuide/Forms/DocumentBasedExample.java @@ -87,7 +87,7 @@ public abstract class DocumentBasedExample implements com.sun.star.lang.XEventLi // grab the focus to the first control m_document.getCurrentView().grabControlFocus(); - // ---------------------------------------------- + // wait for the user to confirm that we can exit if ( waitForUserInput() ) { diff --git a/odk/examples/DevelopersGuide/Forms/HsqlDatabase.java b/odk/examples/DevelopersGuide/Forms/HsqlDatabase.java index d56501ad9f19..0a4e46e48e3b 100644 --- a/odk/examples/DevelopersGuide/Forms/HsqlDatabase.java +++ b/odk/examples/DevelopersGuide/Forms/HsqlDatabase.java @@ -46,21 +46,21 @@ public class HsqlDatabase // the default connection XConnection m_connection; - // -------------------------------------------------------------------------------------------------------- + public HsqlDatabase( XComponentContext _context ) throws Exception { m_context = _context; createDBDocument(); } - // -------------------------------------------------------------------------------------------------------- + public HsqlDatabase( XComponentContext _context, String _existingDocumentURL ) throws Exception { m_context = _context; createDBDocument( _existingDocumentURL ); } - // -------------------------------------------------------------------------------------------------------- + private void createDBDocument( String _docURL ) throws Exception { m_databaseDocumentFile = _docURL; diff --git a/odk/examples/DevelopersGuide/Forms/SalesFilter.java b/odk/examples/DevelopersGuide/Forms/SalesFilter.java index 932cf5c93981..59d979f19e4f 100644 --- a/odk/examples/DevelopersGuide/Forms/SalesFilter.java +++ b/odk/examples/DevelopersGuide/Forms/SalesFilter.java @@ -70,7 +70,7 @@ class SalesFilter implements XActionListener, XPropertyChangeListener, XResetLis m_nPreviousFilterIndex = -1; initFilterDates(); - // ------------------------------------------------------------- + // remember the components m_aDocument = aDocument; m_xSalesForm = xSalesForm; @@ -81,7 +81,7 @@ class SalesFilter implements XActionListener, XPropertyChangeListener, XResetLis try { - // ---------------------------------------------------------- + // init control models m_xFilterList.setPropertyValue( "Dropdown", new Boolean( true ) ); m_xFilterList.setPropertyValue( "LineCount", new Short( (short)11 ) ); @@ -93,7 +93,7 @@ class SalesFilter implements XActionListener, XPropertyChangeListener, XResetLis updateFilterControl(); updateApplyButton(); - // ---------------------------------------------------------- + // add as listener to the events which require action // want to know about changed selection diff --git a/odk/examples/DevelopersGuide/Forms/SingleControlValidation.java b/odk/examples/DevelopersGuide/Forms/SingleControlValidation.java index c54283470963..4cf81b5a53b7 100644 --- a/odk/examples/DevelopersGuide/Forms/SingleControlValidation.java +++ b/odk/examples/DevelopersGuide/Forms/SingleControlValidation.java @@ -102,7 +102,7 @@ public class SingleControlValidation implements XFormComponentValidityListener } m_inputField = controls[ 0 ]; - // ---------------------------------- + controlPos += 4; XPropertySet xLabel = m_formLayer.createControlAndShape( "FixedText", columnPos, controlPos, 70, 4, null ); xLabel.setPropertyValue( "Label", new String( "Status:" ) ); @@ -110,7 +110,7 @@ public class SingleControlValidation implements XFormComponentValidityListener m_statusField = m_formLayer.createControlAndShape( "FixedText", columnPos, controlPos, 70, 4, null ); m_statusField.setPropertyValue( "Label", new String( "" ) ); - // ---------------------------------- + controlPos += 6; xLabel = m_formLayer.createControlAndShape( "FixedText", columnPos, controlPos, 70, 4, null ); xLabel.setPropertyValue( "Label", new String( "Explanation for invalidity:" ) ); diff --git a/odk/examples/DevelopersGuide/Forms/SpreadsheetValueBinding.java b/odk/examples/DevelopersGuide/Forms/SpreadsheetValueBinding.java index 09233addc5dd..e3555b308a0c 100644 --- a/odk/examples/DevelopersGuide/Forms/SpreadsheetValueBinding.java +++ b/odk/examples/DevelopersGuide/Forms/SpreadsheetValueBinding.java @@ -46,7 +46,7 @@ public class SpreadsheetValueBinding extends DocumentBasedExample final short exchangeRow = (short)1; // 2 final Integer backColor = new Integer( 0x00E0E0E0 ); - // ---------------------------------------------------------------------- + // a numeric control XPropertySet numericControl = m_formLayer.insertControlLine( "NumericField", "enter a value", "", 30 ); @@ -59,7 +59,7 @@ public class SpreadsheetValueBinding extends DocumentBasedExample // bind the control model to cell B2 implBind( numericControl, document.createCellBinding( sheet, exchangeColumn, exchangeRow ) ); - // ---------------------------------------------------------------------- + // insert a list box XPropertySet listBox = m_formLayer.insertControlLine( "ListBox", "select an entry", "", 2, 40, 20 ); @@ -81,7 +81,7 @@ public class SpreadsheetValueBinding extends DocumentBasedExample // and also put the list selection index into cell B2 implBind( listBox, document.createListIndexBinding( sheet, exchangeColumn, exchangeRow ) ); - // ---------------------------------------------------------------------- + // fill the cells which we just bound the listbox to XCellRange exchangeSheet = document.getSheet( listSourceSheet ); String[] listContent = new String[] { "first", "second", "third", "forth", "fivth" }; diff --git a/odk/examples/DevelopersGuide/GUI/UnoDialogSample.java b/odk/examples/DevelopersGuide/GUI/UnoDialogSample.java index 60eb85475dd5..aef248ba5c89 100644 --- a/odk/examples/DevelopersGuide/GUI/UnoDialogSample.java +++ b/odk/examples/DevelopersGuide/GUI/UnoDialogSample.java @@ -1296,7 +1296,7 @@ public class UnoDialogSample implements XTextListener, XSpinListener, XActionLis // just in case the listener has been added to several controls, // we make sure we refer to the right one if (sName.equals("CommandButton1")) { - //... + } }catch (com.sun.star.uno.Exception ex){ /* perform individual exception handling here. diff --git a/odk/examples/DevelopersGuide/GUI/UnoMenu.java b/odk/examples/DevelopersGuide/GUI/UnoMenu.java index 87e7fce68085..d72ab7e704ac 100644 --- a/odk/examples/DevelopersGuide/GUI/UnoMenu.java +++ b/odk/examples/DevelopersGuide/GUI/UnoMenu.java @@ -171,7 +171,7 @@ public UnoMenu(XComponentContext _xContext, XMultiComponentFactory _xMCF) { case 8: closeDialog(); default: - //.. + } } diff --git a/odk/examples/DevelopersGuide/OfficeDev/Clipboard/Clipboard.java b/odk/examples/DevelopersGuide/OfficeDev/Clipboard/Clipboard.java index 5dc01aa3fca1..41af02a39613 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Clipboard/Clipboard.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Clipboard/Clipboard.java @@ -45,9 +45,9 @@ import com.sun.star.datatransfer.clipboard.XSystemClipboard; import com.sun.star.text.XTextDocument; import com.sun.star.uno.AnyConverter; -//------------------------------------------------- + // Demonstrates the usage of the clipboard service -//------------------------------------------------- + public class Clipboard { @@ -89,9 +89,9 @@ public class Clipboard XSystemClipboard xClipboard = SystemClipboard.create(xOfficeContext); - //--------------------------------------------------- + // registering as clipboard listener - //--------------------------------------------------- + ClipboardListener aClipListener= new ClipboardListener(); @@ -100,9 +100,9 @@ public class Clipboard // Read ClipBoard readClipBoard(xClipboard); - //--------------------------------------------------- + // becoming a clipboard owner - //--------------------------------------------------- + System.out.println("Becoming a clipboard owner..."); System.out.println(""); @@ -130,9 +130,9 @@ public class Clipboard // Read ClipBoard again readClipBoard(xClipboard); - //--------------------------------------------------- + // unregistering as clipboard listener - //--------------------------------------------------- + xClipboard.removeClipboardListener(aClipListener); // close test document @@ -157,9 +157,9 @@ public class Clipboard public static void readClipBoard(XClipboard xClipboard) throws java.lang.Exception { - //--------------------------------------------------- + // get a list of formats currently on the clipboard - //--------------------------------------------------- + XTransferable xTransferable = xClipboard.getContents(); diff --git a/odk/examples/DevelopersGuide/OfficeDev/Clipboard/ClipboardListener.java b/odk/examples/DevelopersGuide/OfficeDev/Clipboard/ClipboardListener.java index 49efd28c0ea8..21d23ff92b43 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Clipboard/ClipboardListener.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Clipboard/ClipboardListener.java @@ -36,9 +36,9 @@ import com.sun.star.lang.EventObject; import com.sun.star.datatransfer.clipboard.ClipboardEvent; import com.sun.star.datatransfer.clipboard.XClipboardListener; -//----------------------------- + // A simple clipboard listener -//----------------------------- + public class ClipboardListener implements XClipboardListener { diff --git a/odk/examples/DevelopersGuide/OfficeDev/Clipboard/ClipboardOwner.java b/odk/examples/DevelopersGuide/OfficeDev/Clipboard/ClipboardOwner.java index eb745bae4119..94987b89b37c 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Clipboard/ClipboardOwner.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Clipboard/ClipboardOwner.java @@ -36,9 +36,9 @@ import com.sun.star.datatransfer.XTransferable; import com.sun.star.datatransfer.clipboard.XClipboard; import com.sun.star.datatransfer.clipboard.XClipboardOwner; -//-------------------------- + // A simple clipboard owner -//-------------------------- + public class ClipboardOwner implements XClipboardOwner { diff --git a/odk/examples/DevelopersGuide/OfficeDev/Clipboard/TextTransferable.java b/odk/examples/DevelopersGuide/OfficeDev/Clipboard/TextTransferable.java index 291cbbb97e22..8ce14f408a92 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Clipboard/TextTransferable.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Clipboard/TextTransferable.java @@ -37,10 +37,10 @@ import com.sun.star.datatransfer.UnsupportedFlavorException; import com.sun.star.datatransfer.XTransferable; import com.sun.star.uno.Type; -//--------------------------------------- + // A simple transferable containing only // one format, unicode text -//--------------------------------------- + public class TextTransferable implements XTransferable { diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/CustomizeView.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/CustomizeView.java index ea8645d9fc4c..769768b027ca 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/CustomizeView.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/CustomizeView.java @@ -69,7 +69,7 @@ public class CustomizeView extends JPanel private static final String TOOLBAR_OFF = "toolbar off" ; private static final String OBJECTBAR_OFF = "objectbar off" ; - // ____________________ + // member /** @@ -89,7 +89,7 @@ public class CustomizeView extends JPanel private StatusListener m_aToolBarListener ; private StatusListener m_aObjectBarListener; - // ____________________ + /** * ctor @@ -117,7 +117,7 @@ public class CustomizeView extends JPanel this.add(m_cbObjectBar); } - // ____________________ + /** * set new frame for this view @@ -160,7 +160,7 @@ public class CustomizeView extends JPanel m_aObjectBarListener.startListening(); } - // ____________________ + /** * react for click events of the used check boxes @@ -186,7 +186,7 @@ public class CustomizeView extends JPanel /// we must use this frame to dispatch a request com.sun.star.frame.XFrame m_xFrame; - //_____________________ + /** * ctor @@ -201,7 +201,7 @@ public class CustomizeView extends JPanel m_xFrame = xFrame; } - //_____________________ + /** * callback for action events @@ -242,7 +242,7 @@ public class CustomizeView extends JPanel FunctionHelper.execute(m_xFrame,aURL,lProperties,null); } - // ____________________ + /** * callback for disposing events @@ -264,7 +264,7 @@ public class CustomizeView extends JPanel } } - // ____________________ + /** * If this java application shutdown - we must cancel all current existing diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/Desk.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/Desk.java index 9641dc8864a9..6553b3b2ff20 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/Desk.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/Desk.java @@ -44,7 +44,7 @@ import java.lang.String; */ public class Desk { - // ____________________ + /** * main diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/DocumentView.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/DocumentView.java index 7cbb0e3ecf8b..9e679b1eed11 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/DocumentView.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/DocumentView.java @@ -61,7 +61,7 @@ public class DocumentView extends JFrame implements com.sun.star.lang.XEventListener, // react for Frame::disposing() IShutdownListener // react for System.exit() { - // ____________________ + /** * const @@ -73,7 +73,7 @@ public class DocumentView extends JFrame public static final String COMMAND_EXPORT = "export" ; public static final String COMMAND_EXIT = "exit" ; - // ____________________ + /** * @member mxFrame office frame which contains the document of this view @@ -108,7 +108,7 @@ public class DocumentView extends JFrame private boolean mbDead ; - // ____________________ + /** * ctor @@ -195,7 +195,7 @@ public class DocumentView extends JFrame this.enableEvents(AWTEvent.WINDOW_EVENT_MASK); } - // ____________________ + /** * Create the view frame for showing the office documents on demand. @@ -241,7 +241,7 @@ public class DocumentView extends JFrame } } - // ____________________ + /** * Different ways to load any URL from outside (may be by the command line) @@ -252,7 +252,7 @@ public class DocumentView extends JFrame load(sURL,new com.sun.star.beans.PropertyValue[0]); } - // ____________________ + public void load(String sURL, com.sun.star.beans.PropertyValue[] lArguments) { @@ -269,7 +269,7 @@ public class DocumentView extends JFrame } } - // ____________________ + public void save() { @@ -282,7 +282,7 @@ public class DocumentView extends JFrame FunctionHelper.saveDocument(xDocument); } - // ____________________ + public void exportHTML(String sURL) { @@ -295,7 +295,7 @@ public class DocumentView extends JFrame FunctionHelper.saveAsHTML(xDocument,sURL); } - // ____________________ + /** * Overridden so we can react for window closing of this view. @@ -315,7 +315,7 @@ public class DocumentView extends JFrame } } - // ____________________ + /** * Here we can react for System.exit() normaly. @@ -355,7 +355,7 @@ public class DocumentView extends JFrame ViewContainer.getGlobalContainer().removeView(this); } - // ____________________ + /** * callback from our internal saved frame @@ -372,7 +372,7 @@ public class DocumentView extends JFrame mxFrame = null; } - // ____________________ + /** * This inner class is used to react for events of our own UI controls. @@ -380,7 +380,7 @@ public class DocumentView extends JFrame */ private class Reactor implements ActionListener { - // ____________________ + /** * This method react for pressed buttons or selected check boxes. @@ -388,7 +388,7 @@ public class DocumentView extends JFrame public void actionPerformed(ActionEvent aEvent) { String sCommand = aEvent.getActionCommand(); - //----------------------------- + // open any file from disk if( sCommand.compareTo(COMMAND_OPEN) == 0 ) { @@ -397,14 +397,14 @@ public class DocumentView extends JFrame DocumentView.this.load(sURL); } else - //----------------------------- + // save current document if( sCommand.compareTo(COMMAND_SAVE) == 0 ) { DocumentView.this.save(); } else - //----------------------------- + // export current document to html if( sCommand.compareTo(COMMAND_EXPORT) == 0 ) { @@ -413,7 +413,7 @@ public class DocumentView extends JFrame DocumentView.this.exportHTML(sURL); } else - //----------------------------- + // exit application if( sCommand.compareTo(COMMAND_EXIT) == 0 ) { diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/FunctionHelper.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/FunctionHelper.java index 88b80d34037b..6060292b95b3 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/FunctionHelper.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/FunctionHelper.java @@ -61,7 +61,7 @@ import java.net.*; */ public class FunctionHelper { - // ____________________ + /** * This convert an URL (formated as a string) to a struct com.sun.star.util.URL. @@ -124,7 +124,7 @@ public class FunctionHelper return aURL; } - // ____________________ + /** * create a new empty target frame @@ -165,7 +165,7 @@ public class FunctionHelper return xFrame; } - // ____________________ + /** * create a new window which can be used as container window of an office frame @@ -323,7 +323,7 @@ public class FunctionHelper return xWindow; } - // ____________________ + /** * This method create a new empty child frame on desktop instance of remote office. @@ -423,7 +423,7 @@ public class FunctionHelper return xFrame; } - // ____________________ + /** * Dispatch an URL to given frame. @@ -488,7 +488,7 @@ public class FunctionHelper return xDispatcher; } - // ____________________ + /** * Dispatch an URL to given frame. @@ -535,7 +535,7 @@ public class FunctionHelper } } - // ____________________ + /** * Load document specified by an URL into given frame synchronously. @@ -627,7 +627,7 @@ public class FunctionHelper return xDocument; } - // ____________________ + /** * Save currently loaded document of given frame. @@ -675,7 +675,7 @@ public class FunctionHelper } } - // ____________________ + /** * It try to export given document in HTML format. @@ -780,7 +780,7 @@ public class FunctionHelper } } - // ____________________ + /** * Try to close the document without any saving of modifications. @@ -855,7 +855,7 @@ public class FunctionHelper } } - // ____________________ + /** * Try to close the frame instead of the document. @@ -918,7 +918,7 @@ public class FunctionHelper return bClosed; } - // ____________________ + /** * Try to find an unique frame name, which isn't currently used inside @@ -979,7 +979,7 @@ public class FunctionHelper return sName; } - // ____________________ + /** * helper to get a file URL selected by user @@ -1042,7 +1042,7 @@ public class FunctionHelper return sFileURL; } - // ____________________ + /** * @member maLastDir save the last visited directory of used file open/save dialog diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/IOnewayLink.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/IOnewayLink.java index 33a6b3c79a4e..1ad68bb82f4b 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/IOnewayLink.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/IOnewayLink.java @@ -48,7 +48,7 @@ import java.util.ArrayList; */ public interface IOnewayLink { - // _______________________________ + /** * @param nRequest diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/Interceptor.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/Interceptor.java index 88eeb2fd322f..c8e300eadca6 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/Interceptor.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/Interceptor.java @@ -63,7 +63,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, IShutdownListener, IOnewayLink { - // ____________________ + /** * const @@ -74,7 +74,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, "slot:5300" , ".uno:Quit" }; - // ____________________ + /** * @member m_xMaster use this interceptor if he doesn't handle queried dispatch request @@ -89,7 +89,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, private boolean m_bIsRegistered ; private boolean m_bDead ; - // ____________________ + /** * ctor @@ -111,7 +111,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, m_bDead = false ; } - //_____________________ + /** * start working as frame action listener really. @@ -140,7 +140,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, } } - //_____________________ + /** * In case we got an oneway listener callback - we had to use the office @@ -188,7 +188,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, } } - // ____________________ + /** * call back for frame action events @@ -243,7 +243,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, aExecutor.start(); } - // ____________________ + /** * Indicates using of us as an interceptor. @@ -282,7 +282,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, } - //_____________________ + /** * Internal call back for frame action events, triggered by the used @@ -342,7 +342,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, } } - // ____________________ + /** * Implementation of interface XDispatchProviderInterceptor @@ -361,7 +361,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, } } - // ____________________ + public void setSlaveDispatchProvider(com.sun.star.frame.XDispatchProvider xSlave) { @@ -371,7 +371,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, } } - // ____________________ + public com.sun.star.frame.XDispatchProvider getMasterDispatchProvider() { @@ -381,7 +381,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, } } - // ____________________ + public void setMasterDispatchProvider(com.sun.star.frame.XDispatchProvider xMaster) { @@ -391,7 +391,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, } } - // ____________________ + /** * Implementation of interface XDispatchProvider @@ -457,7 +457,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, return null; } - // ____________________ + public com.sun.star.frame.XDispatch[] queryDispatches(/*IN*/ com.sun.star.frame.DispatchDescriptor[] lDescriptor) { @@ -479,7 +479,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, return lDispatcher; } - // ____________________ + /** * This method is called if this interceptor "wins the request". @@ -520,7 +520,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, } } - // ____________________ + /** * Notification of status listener isn't guaranteed (instead of listener on XNotifyingDispatch interface). @@ -545,13 +545,13 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, }*/ } - // ____________________ + public /*ONEWAY*/ void removeStatusListener(/*IN*/ com.sun.star.frame.XStatusListener xListener,/*IN*/ com.sun.star.util.URL aURL) { } - // ____________________ + /** * Implements (optional!) optimization for interceptor mechanism. @@ -568,7 +568,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, return INTERCEPTED_URLS; } - // ____________________ + /** * This class listen on the intercepted frame to free all used resources on closing. @@ -593,7 +593,7 @@ public class Interceptor implements com.sun.star.frame.XFrameActionListener, shutdown(); } - // ____________________ + /** * If this java application shutdown - we must cancel all current existing diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/JavaWindowPeerFake.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/JavaWindowPeerFake.java index 3bc089543687..4405f05ebf09 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/JavaWindowPeerFake.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/JavaWindowPeerFake.java @@ -47,7 +47,7 @@ class JavaWindowPeerFake implements com.sun.star.awt.XSystemDependentWindowPeer, maView = aNative; } - // ____________________ + /** * Implementation of XSystemDependentWindowPeer (that's all we really need). * This method is called back from the Office toolkit to retrieve the system data. diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/NativeView.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/NativeView.java index 270baf201062..7fd846983d74 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/NativeView.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/NativeView.java @@ -50,7 +50,7 @@ import java.awt.*; public class NativeView extends java.awt.Canvas { - // ____________________ + /** * ctor @@ -67,7 +67,7 @@ public class NativeView extends java.awt.Canvas this.setBackground(Color.white); } - // ____________________ + /** * Overload this method to make necessary initializations here. @@ -84,7 +84,7 @@ public class NativeView extends java.awt.Canvas getHWND(); } - // ____________________ + /** * to guarantee right resize handling inside a swing container @@ -106,7 +106,7 @@ public class NativeView extends java.awt.Canvas return new Dimension(100,100); } - // ____________________ + /** * overload paint routine to show provide against @@ -125,7 +125,7 @@ public class NativeView extends java.awt.Canvas } } - // ____________________ + /** * JNI interface of this class @@ -156,7 +156,7 @@ public class NativeView extends java.awt.Canvas return maHandle; } - // ____________________ + /** * for using of the JNI methods it's necessary to load @@ -167,7 +167,7 @@ public class NativeView extends java.awt.Canvas System.loadLibrary("nativeview"); } - // ____________________ + /** * @member maHandle system window handle diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/OfficeConnect.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/OfficeConnect.java index e8a345ce1c4b..fb14f5acdacc 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/OfficeConnect.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/OfficeConnect.java @@ -52,7 +52,7 @@ import java.lang.String; */ public class OfficeConnect { - // ____________________ + /** * At first call we create static connection object and open connection to an @@ -65,7 +65,7 @@ public class OfficeConnect maConnection = new OfficeConnect(); } - // ____________________ + /** * close connection to remote office if it exist @@ -80,7 +80,7 @@ public class OfficeConnect } } - // ____________________ + /** * ctor @@ -110,7 +110,7 @@ public class OfficeConnect } } - // ____________________ + /** * create uno components inside remote office process @@ -145,7 +145,7 @@ public class OfficeConnect return aResult; } - // ____________________ + /** * same as "createRemoteInstance()" but supports additional parameter for @@ -176,7 +176,7 @@ public class OfficeConnect return aResult; } - // ____________________ + /** * returns remote component context of the connected office @@ -186,7 +186,7 @@ public class OfficeConnect return mxOfficeContext; } - // ____________________ + /** * member diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/OnewayExecutor.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/OnewayExecutor.java index 51435cb5b6a2..bd8db66ed431 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/OnewayExecutor.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/OnewayExecutor.java @@ -48,7 +48,7 @@ import java.util.ArrayList; */ class OnewayExecutor extends Thread { - // _______________________________ + /** * const @@ -66,7 +66,7 @@ class OnewayExecutor extends Thread public static final boolean ENCODE_PARAMS = true ; public static final boolean DECODE_PARAMS = false ; - // _______________________________ + /** * @member m_rLink the object, which wish to be called back by this thread @@ -78,7 +78,7 @@ class OnewayExecutor extends Thread private int m_nRequest ; private ArrayList<Object> m_lParams ; - // _______________________________ + /** * ctor @@ -114,7 +114,7 @@ class OnewayExecutor extends Thread System.out.println("ctor ... m_lParams == null"); } - // _______________________________ + /** * implements the thread function @@ -133,7 +133,7 @@ class OnewayExecutor extends Thread m_rLink.execOneway( m_nRequest, m_lParams ); } - // _______________________________ + /** * static helper! @@ -142,7 +142,7 @@ class OnewayExecutor extends Thread * must be coded. It's not a must to use it - but you can ... */ - // _______________________________ + public static ArrayList<Object> encodeDispatch( com.sun.star.util.URL[] aURL, diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusListener.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusListener.java index 29c4fffecda7..6e65c8375a7a 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusListener.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusListener.java @@ -67,7 +67,7 @@ class StatusListener implements com.sun.star.frame.XStatusListener, IShutdownListener, IOnewayLink { - //_____________________ + /** * @member m_rControl reference to the UI control, which should be updated @@ -90,7 +90,7 @@ class StatusListener implements com.sun.star.frame.XStatusListener, private boolean m_bIsStatusListener; private boolean m_bDead ; - //_____________________ + /** * ctor @@ -115,7 +115,7 @@ class StatusListener implements com.sun.star.frame.XStatusListener, m_aURL = FunctionHelper.parseURL(sURL); } - //_____________________ + /** * start working as frame action listener really. @@ -146,7 +146,7 @@ class StatusListener implements com.sun.star.frame.XStatusListener, } } - //_____________________ + /** * In case we got an oneway listener callback - we had to use the office @@ -180,7 +180,7 @@ class StatusListener implements com.sun.star.frame.XStatusListener, } } - //_____________________ + /** * This is the callback method for such frame action events, we listen for. @@ -222,7 +222,7 @@ class StatusListener implements com.sun.star.frame.XStatusListener, aExecutor.start(); } - //_____________________ + /** * This is the callback method for the status we listen for an wish to show it @@ -252,7 +252,7 @@ class StatusListener implements com.sun.star.frame.XStatusListener, // look for the right type ofthe UI control // Following actions depend on it. - //............................................................. + // it's a check box if (m_rControl instanceof JCheckBox) { @@ -271,7 +271,7 @@ class StatusListener implements com.sun.star.frame.XStatusListener, aBox.setText(m_sFalseText); } else - //............................................................. + // it's a label if (m_rControl instanceof JLabel) { @@ -305,7 +305,7 @@ class StatusListener implements com.sun.star.frame.XStatusListener, } } - //_____________________ + /** * Internal call back for frame action events, triggered by the used @@ -377,7 +377,7 @@ class StatusListener implements com.sun.star.frame.XStatusListener, } } - // ____________________ + /** * callback for disposing events @@ -414,7 +414,7 @@ class StatusListener implements com.sun.star.frame.XStatusListener, shutdown(); } - // ____________________ + /** * If this java application shutdown - we must cancel all current existing diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusView.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusView.java index aad53937aaae..08616cfe617d 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusView.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/StatusView.java @@ -61,7 +61,7 @@ import java.lang.String; public class StatusView extends JPanel implements IShutdownListener { - // ____________________ + /** * const @@ -73,7 +73,7 @@ public class StatusView extends JPanel public static final String FEATUREURL_ITALIC = "slot:10008"; public static final String FEATUREURL_UNDERLINE = "slot:10014"; - // ____________________ + /** * const @@ -91,7 +91,7 @@ public class StatusView extends JPanel public static final String ITALIC_ON = "X" ; public static final String UNDERLINE_ON = "X" ; - // ____________________ + /** * @member mlaFontValue shows status of font name @@ -118,7 +118,7 @@ public class StatusView extends JPanel private StatusListener m_aUnderlineListener ; private StatusListener m_aItalicListener ; - // ____________________ + /** * ctor @@ -201,7 +201,7 @@ public class StatusView extends JPanel m_laUnderlineValue.setText(UNDERLINE_OFF); } - // ____________________ + /** * Set new frame for this view and start listening for events imedatly. @@ -235,7 +235,7 @@ public class StatusView extends JPanel m_aUnderlineListener.startListening(); } - // ____________________ + /** * If this java application shutdown - we must cancel all current existing diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/ViewContainer.java b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/ViewContainer.java index 5b9851188aea..ef632f98b0f2 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/ViewContainer.java +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/ViewContainer.java @@ -49,7 +49,7 @@ import java.util.*; */ public class ViewContainer extends Thread { - // ____________________ + /** * provides a singleton view container @@ -65,7 +65,7 @@ public class ViewContainer extends Thread return maSingleton; } - // ____________________ + /** * ctor @@ -80,7 +80,7 @@ public class ViewContainer extends Thread Runtime.getRuntime().addShutdownHook(this); } - // ____________________ + /** * This register a new view inside this global container @@ -97,7 +97,7 @@ public class ViewContainer extends Thread } } - // ____________________ + /** * This deregister a view from this global container. @@ -158,7 +158,7 @@ public class ViewContainer extends Thread } } - // ____________________ + /** * add/remove listener for possibe shutdown events @@ -172,7 +172,7 @@ public class ViewContainer extends Thread } } - // ____________________ + public void removeListener( IShutdownListener rListener ) { @@ -183,7 +183,7 @@ public class ViewContainer extends Thread } } - // ____________________ + /** * Is called from current runtime system of the java machine @@ -237,14 +237,14 @@ public class ViewContainer extends Thread } } - // ____________________ + /** * @const BASICNAME it's used to create uinque names for all regieterd views */ private static final String BASICNAME = "Document View "; - // ____________________ + /** * @member mbInplace indicates using of inplace office frames instead of outplace ones diff --git a/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/AsciiFilter/AsciiReplaceFilter.java b/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/AsciiFilter/AsciiReplaceFilter.java index 1dc93286f94c..81303623f517 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/AsciiFilter/AsciiReplaceFilter.java +++ b/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/AsciiFilter/AsciiReplaceFilter.java @@ -85,7 +85,7 @@ public class AsciiReplaceFilter public static final int FILTERPROC_BREAK = 1; public static final int FILTERPROC_STOPPED = 2; - //______________________________ + // member @@ -102,7 +102,7 @@ public class AsciiReplaceFilter // we need a flag to cancel any running filter operation private int m_nFilterProcState; - //______________________________ + // native interface /** * special debug helper to get an idea how expensive @@ -122,7 +122,7 @@ public class AsciiReplaceFilter m_nLast = nNow; } - //______________________________ + // native interface /** * The constructor to initialize every instance @@ -154,7 +154,7 @@ public class AsciiReplaceFilter m_nStart = m_nLast; } - //______________________________ + // interface XInitialization /** * used for initializing after creation @@ -210,7 +210,7 @@ public class AsciiReplaceFilter measure("} initialize"); } - //______________________________ + // interface XNamed /** * For external user of us we must provide our internal filter name @@ -238,7 +238,7 @@ public class AsciiReplaceFilter { } - //______________________________ + // interface XImporter /** * This interface is used to tell us: "you will be used for importing a document". @@ -274,7 +274,7 @@ public class AsciiReplaceFilter measure("} setTargetDocument"); } - //______________________________ + // interface XExporter /** * This interface is used to tell us: "you will be used for exporting a document". @@ -311,7 +311,7 @@ public class AsciiReplaceFilter } - //______________________________ + // interface XFilter /** * Implements the real filter method. We detect if it must be an import or an export. @@ -387,7 +387,7 @@ public class AsciiReplaceFilter measure("} cancel"); } - //______________________________ + // private helper /** * This helper function imports a simple ascii text file into @@ -630,7 +630,7 @@ public class AsciiReplaceFilter } - //______________________________ + // interface XServiceInfo /** * This method returns an array of all supported service names. diff --git a/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/AsciiFilter/FilterOptions.java b/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/AsciiFilter/FilterOptions.java index 73198adb717a..2a14247d1379 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/AsciiFilter/FilterOptions.java +++ b/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/AsciiFilter/FilterOptions.java @@ -56,7 +56,7 @@ import com.sun.star.uno.UnoRuntime; public class FilterOptions { - //_____________________________________ + // public member to provide these options to our outside filter class public com.sun.star.io.XInputStream m_xInput ; public com.sun.star.io.XOutputStream m_xOutput ; @@ -67,12 +67,12 @@ public class FilterOptions public boolean m_bCaseChange ; public boolean m_bLower ; - //_____________________________________ + // private members for internal things private XMultiComponentFactory m_xMCF ; private XComponentContext m_Ctx ; - //_____________________________________ + // interface /** * creates a new instance of this class @@ -187,7 +187,7 @@ public class FilterOptions return(m_xInput!=null || m_xOutput!=null); } - //_____________________________________ + // helper /** * In case we couldn't found any valid stream inside the given MediaDescriptor, diff --git a/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/FlatXmlFilterDetection/filterdetect.cxx b/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/FlatXmlFilterDetection/filterdetect.cxx index 84731ba73d6d..4baad95d7070 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/FlatXmlFilterDetection/filterdetect.cxx +++ b/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/FlatXmlFilterDetection/filterdetect.cxx @@ -116,7 +116,7 @@ OUString SAL_CALL FilterDetect::detect(Sequence< PropertyValue >& aArguments ) // flatxml starts with an office:document element. this element // conatains a clas="..." attribut by which we can deduct the // type of document that is to be loaded - // + // WARNING: // parsing the plain text of the document is an easy way to do this // but not the purest solution, since namespaces and other xml details diff --git a/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/FlatXmlFilter_java/FlatXml.java b/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/FlatXmlFilter_java/FlatXml.java index b6b0383531c2..b7c23161709e 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/FlatXmlFilter_java/FlatXml.java +++ b/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/FlatXmlFilter_java/FlatXml.java @@ -244,7 +244,7 @@ public class FlatXml implements XImportFilter, XExportFilter, XServiceName, m_xHandler.setDocumentLocator(xLocator); } - // ------------------------------------------------------------ + // component management public static XSingleServiceFactory __getServiceFactory(String implName, diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/OneInstanceFactory.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/OneInstanceFactory.java index 114d1bda2e94..2a33ecb4d6cf 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/OneInstanceFactory.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/OneInstanceFactory.java @@ -42,11 +42,11 @@ import com.sun.star.uno.UnoRuntime; import java.lang.reflect.Constructor; -// + // purpose of this class is to provide a service factory that instantiates // the services only once (as long as this factory itself exists) // and returns only reference to that instance. -// + public class OneInstanceFactory implements XSingleServiceFactory, @@ -71,9 +71,9 @@ public class OneInstanceFactory implements xInstantiatedService = null; } - //********************** + // XSingleServiceFactory - //********************** + public Object createInstance() throws com.sun.star.uno.Exception, com.sun.star.uno.RuntimeException @@ -123,9 +123,9 @@ public class OneInstanceFactory implements } - //************* + // XServiceInfo - //************* + public boolean supportsService( String aServiceName ) throws com.sun.star.uno.RuntimeException { diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper.java index 2932a7791367..98f7e27e259e 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper.java @@ -138,9 +138,9 @@ public class PropChgHelper implements // __________ interface methods __________ - //*************** + // XEventListener - //*************** + public void disposing( EventObject aSource ) throws com.sun.star.uno.RuntimeException { @@ -150,18 +150,18 @@ public class PropChgHelper implements } } - //************************ + // XPropertyChangeListener - //************************ + public void propertyChange( PropertyChangeEvent aEvt ) throws com.sun.star.uno.RuntimeException { // will be overloaded in derived classes } - //****************************** + // XLinguServiceEventBroadcaster - //****************************** + public boolean addLinguServiceEventListener( XLinguServiceEventListener xListener ) throws com.sun.star.uno.RuntimeException diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Hyph.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Hyph.java index cb0e2811c0a4..95047d436bee 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Hyph.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Hyph.java @@ -46,9 +46,9 @@ public class PropChgHelper_Hyph extends PropChgHelper super( xEvtSource, aPropNames ); } - //************************ + // XPropertyChangeListener - //************************ + public void propertyChange( PropertyChangeEvent aEvt ) throws com.sun.star.uno.RuntimeException { diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Spell.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Spell.java index 68c3c3b46d69..cf1aef3d0f33 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Spell.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/PropChgHelper_Spell.java @@ -46,9 +46,9 @@ public class PropChgHelper_Spell extends PropChgHelper super( xEvtSource, aPropNames ); } - //************************ + // XPropertyChangeListener - //************************ + public void propertyChange( PropertyChangeEvent aEvt ) throws com.sun.star.uno.RuntimeException { diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleHyphenator.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleHyphenator.java index be0b47d90134..ffa8358227cd 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleHyphenator.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleHyphenator.java @@ -177,9 +177,9 @@ public class SampleHyphenator extends ComponentBase implements // __________ interface methods __________ - //***************** + //XSupportedLocales - //***************** + public Locale[] getLocales() throws com.sun.star.uno.RuntimeException { @@ -202,9 +202,9 @@ public class SampleHyphenator extends ComponentBase implements return bRes; } - //*********** + //XHyphenator - //*********** + public XHyphenatedWord hyphenate( String aWord, Locale aLocale, short nMaxLeading, PropertyValue[] aProperties ) @@ -400,9 +400,9 @@ public class SampleHyphenator extends ComponentBase implements return xRes; } - //***************************** + //XLinguServiceEventBroadcaster - //***************************** + public boolean addLinguServiceEventListener ( XLinguServiceEventListener xLstnr ) throws com.sun.star.uno.RuntimeException @@ -423,18 +423,18 @@ public class SampleHyphenator extends ComponentBase implements return bRes; } - //******************** + // XServiceDisplayName - //******************** + public String getServiceDisplayName( Locale aLocale ) throws com.sun.star.uno.RuntimeException { return "Java Samples"; } - //**************** + // XInitialization - //**************** + public void initialize( Object[] aArguments ) throws com.sun.star.uno.Exception, com.sun.star.uno.RuntimeException @@ -450,9 +450,9 @@ public class SampleHyphenator extends ComponentBase implements } - //************* + // XServiceInfo - //************* + public boolean supportsService( String aServiceName ) throws com.sun.star.uno.RuntimeException { diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleSpellChecker.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleSpellChecker.java index 2ae92beb043b..00fbab8365d9 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleSpellChecker.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleSpellChecker.java @@ -253,9 +253,9 @@ public class SampleSpellChecker extends ComponentBase implements // __________ interface methods __________ - //***************** + //XSupportedLocales - //***************** + public Locale[] getLocales() throws com.sun.star.uno.RuntimeException { @@ -279,9 +279,9 @@ public class SampleSpellChecker extends ComponentBase implements } - //************* + //XSpellChecker - //************* + public boolean isValid( String aWord, Locale aLocale, PropertyValue[] aProperties ) @@ -344,9 +344,9 @@ public class SampleSpellChecker extends ComponentBase implements } - //***************************** + //XLinguServiceEventBroadcaster - //***************************** + public boolean addLinguServiceEventListener ( XLinguServiceEventListener xLstnr ) throws com.sun.star.uno.RuntimeException @@ -367,18 +367,18 @@ public class SampleSpellChecker extends ComponentBase implements return bRes; } - //******************** + // XServiceDisplayName - //******************** + public String getServiceDisplayName( Locale aLocale ) throws com.sun.star.uno.RuntimeException { return "Java Samples"; } - //**************** + // XInitialization - //**************** + public void initialize( Object[] aArguments ) throws com.sun.star.uno.Exception, com.sun.star.uno.RuntimeException @@ -393,9 +393,9 @@ public class SampleSpellChecker extends ComponentBase implements } } - //************* + // XServiceInfo - //************* + public boolean supportsService( String aServiceName ) throws com.sun.star.uno.RuntimeException { diff --git a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleThesaurus.java b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleThesaurus.java index 967d5c54cdbb..d51ccb71a440 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleThesaurus.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Linguistic/SampleThesaurus.java @@ -135,9 +135,9 @@ public class SampleThesaurus extends ComponentBase implements // __________ interface methods __________ - //***************** + //XSupportedLocales - //***************** + public Locale[] getLocales() throws com.sun.star.uno.RuntimeException { @@ -158,9 +158,9 @@ public class SampleThesaurus extends ComponentBase implements return bRes; } - //********** + //XThesaurus - //********** + public XMeaning[] queryMeanings( String aTerm, Locale aLocale, PropertyValue[] aProperties ) @@ -203,18 +203,18 @@ public class SampleThesaurus extends ComponentBase implements } - //******************** + // XServiceDisplayName - //******************** + public String getServiceDisplayName( Locale aLocale ) throws com.sun.star.uno.RuntimeException { return "Java Samples"; } - //**************** + // XInitialization - //**************** + public void initialize( Object[] aArguments ) throws com.sun.star.uno.Exception, com.sun.star.uno.RuntimeException @@ -229,9 +229,9 @@ public class SampleThesaurus extends ComponentBase implements } } - //************* + // XServiceInfo - //************* + public boolean supportsService( String aServiceName ) throws com.sun.star.uno.RuntimeException { diff --git a/odk/examples/DevelopersGuide/OfficeDev/Number_Formats.java b/odk/examples/DevelopersGuide/OfficeDev/Number_Formats.java index eb536ce02b15..d620d8e431da 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/Number_Formats.java +++ b/odk/examples/DevelopersGuide/OfficeDev/Number_Formats.java @@ -56,7 +56,7 @@ public class Number_Formats // __________ public members and methods __________ - // ____________________ + public static void main( String args[] ) { @@ -76,7 +76,7 @@ public class Number_Formats System.exit(0); } - // ____________________ + public void doFunction() throws RuntimeException, Exception { @@ -178,7 +178,7 @@ public class Number_Formats xColPropSet.setPropertyValue( "OptimalWidth", new Boolean(true) ); } - // ____________________ + public Number_Formats( String[] args ) throws java.lang.Exception { @@ -214,7 +214,7 @@ public class Number_Formats private XSpreadsheet maSheet; // the first sheet - // ____________________ + /** init the first sheet */ diff --git a/odk/examples/DevelopersGuide/OfficeDev/OfficeConnect.java b/odk/examples/DevelopersGuide/OfficeDev/OfficeConnect.java index 47bf1bb74b04..be5404ae1965 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/OfficeConnect.java +++ b/odk/examples/DevelopersGuide/OfficeDev/OfficeConnect.java @@ -51,7 +51,7 @@ import java.lang.String; */ public class OfficeConnect { - // ____________________ + /** * At first call we create static connection object and get the remote office @@ -69,14 +69,14 @@ public class OfficeConnect return maConnection; } - // ____________________ + public static synchronized OfficeConnect getConnection() { return maConnection; } - // ____________________ + /** * ctor @@ -93,7 +93,7 @@ public class OfficeConnect mxServiceManager = mxOfficeContext.getServiceManager(); } - // ____________________ + /** * create uno components inside remote office process @@ -125,7 +125,7 @@ public class OfficeConnect return aResult; } - // ____________________ + /** * same as "createRemoteInstance()" but supports additional parameter for initializing created object @@ -154,7 +154,7 @@ public class OfficeConnect return aResult; } - // ____________________ + /** * member diff --git a/odk/examples/DevelopersGuide/Spreadsheet/GeneralTableSample.java b/odk/examples/DevelopersGuide/Spreadsheet/GeneralTableSample.java index 4b1682af2c7e..b018c55be9ef 100644 --- a/odk/examples/DevelopersGuide/Spreadsheet/GeneralTableSample.java +++ b/odk/examples/DevelopersGuide/Spreadsheet/GeneralTableSample.java @@ -43,7 +43,7 @@ import com.sun.star.uno.RuntimeException; public class GeneralTableSample extends SpreadsheetDocHelper { -// ________________________________________________________________ + public static void main( String args[] ) { @@ -64,7 +64,7 @@ public class GeneralTableSample extends SpreadsheetDocHelper System.exit( 0 ); } -// ________________________________________________________________ + /// This sample function modifies cells and cell ranges. public void doSampleFunction() throws RuntimeException, Exception @@ -217,12 +217,12 @@ public class GeneralTableSample extends SpreadsheetDocHelper xSheet.getCellByPosition( 2, 9 ).setFormula( aText ); } -// ________________________________________________________________ + public GeneralTableSample( String[] args ) { super( args ); } -// ________________________________________________________________ + } diff --git a/odk/examples/DevelopersGuide/Spreadsheet/SpreadsheetDocHelper.java b/odk/examples/DevelopersGuide/Spreadsheet/SpreadsheetDocHelper.java index 58dbf4873d64..0526a474ae7b 100644 --- a/odk/examples/DevelopersGuide/Spreadsheet/SpreadsheetDocHelper.java +++ b/odk/examples/DevelopersGuide/Spreadsheet/SpreadsheetDocHelper.java @@ -56,7 +56,7 @@ public class SpreadsheetDocHelper // private com.sun.star.lang.XMultiServiceFactory mxMSFactory; private com.sun.star.sheet.XSpreadsheetDocument mxDocument; -// ________________________________________________________________ + public SpreadsheetDocHelper( String[] args ) { @@ -151,7 +151,7 @@ public class SpreadsheetDocHelper return xSheet; } -// ________________________________________________________________ + // Methods to fill values into cells. /** Writes a double value into a spreadsheet. @@ -249,7 +249,7 @@ public class SpreadsheetDocHelper xPropSet.setPropertyValue( "CharWeight", new Float( com.sun.star.awt.FontWeight.BOLD ) ); } -// ________________________________________________________________ + // Methods to create cell addresses and range addresses. /** Creates a com.sun.star.table.CellAddress and initializes it @@ -277,7 +277,7 @@ public class SpreadsheetDocHelper return xAddr.getRangeAddress(); } -// ________________________________________________________________ + // Methods to convert cell addresses and range addresses to strings. /** Returns the text address of the cell. @@ -345,7 +345,7 @@ public class SpreadsheetDocHelper return aStr; } -// ________________________________________________________________ + // Connect to a running office that is accepting connections. private void connect() @@ -384,5 +384,5 @@ public class SpreadsheetDocHelper com.sun.star.sheet.XSpreadsheetDocument.class, xComponent ); } -// ________________________________________________________________ + } diff --git a/odk/examples/DevelopersGuide/Spreadsheet/SpreadsheetSample.java b/odk/examples/DevelopersGuide/Spreadsheet/SpreadsheetSample.java index 62726efafcbf..619ee83ee4ae 100644 --- a/odk/examples/DevelopersGuide/Spreadsheet/SpreadsheetSample.java +++ b/odk/examples/DevelopersGuide/Spreadsheet/SpreadsheetSample.java @@ -43,7 +43,7 @@ import com.sun.star.uno.AnyConverter; public class SpreadsheetSample extends SpreadsheetDocHelper { -// ________________________________________________________________ + public static void main( String args[] ) { @@ -63,14 +63,14 @@ public class SpreadsheetSample extends SpreadsheetDocHelper System.exit( 0 ); } -// ________________________________________________________________ + public SpreadsheetSample( String[] args ) { super( args ); } -// ________________________________________________________________ + /** This sample function performs all changes on the document. */ public void doSampleFunction() @@ -197,7 +197,7 @@ public class SpreadsheetSample extends SpreadsheetDocHelper } } -// ________________________________________________________________ + /** All samples regarding the service com.sun.star.sheet.SheetCell. */ private void doCellSamples() throws RuntimeException, Exception @@ -292,7 +292,7 @@ public class SpreadsheetSample extends SpreadsheetDocHelper xAnnotation.setIsVisible( true ); } -// ________________________________________________________________ + /** All samples regarding the service com.sun.star.sheet.SheetCellRange. */ private void doCellRangeSamples() throws RuntimeException, Exception @@ -527,7 +527,7 @@ public class SpreadsheetSample extends SpreadsheetDocHelper com.sun.star.sheet.XCellSeries.class, xSheet.getCellRangeByName( aRange ) ); } -// ________________________________________________________________ + /** All samples regarding cell range collections. */ private void doCellRangesSamples() throws RuntimeException, Exception @@ -591,7 +591,7 @@ public class SpreadsheetSample extends SpreadsheetDocHelper + " resulting list: " + xContainer.getRangeAddressesAsString() ); } -// ________________________________________________________________ + /** All samples regarding cell cursors. */ private void doCellCursorSamples() throws RuntimeException, Exception @@ -621,7 +621,7 @@ public class SpreadsheetSample extends SpreadsheetDocHelper System.out.println( "The used area is: " + getCellRangeAddressString( xCursor, true ) ); } -// ________________________________________________________________ + /** All samples regarding the formatting of cells and ranges. */ private void doFormattingSamples() throws RuntimeException, Exception @@ -790,7 +790,7 @@ public class SpreadsheetSample extends SpreadsheetDocHelper xPropSet.setPropertyValue( "ConditionalFormat", xEntries ); } -// ________________________________________________________________ + /** All samples regarding the spreadsheet document. */ private void doDocumentSamples() throws RuntimeException, Exception @@ -938,7 +938,7 @@ public class SpreadsheetSample extends SpreadsheetDocHelper xScenario.apply(); } -// ________________________________________________________________ + private void doNamedRangesSamples() throws RuntimeException, Exception { @@ -1003,7 +1003,7 @@ public class SpreadsheetSample extends SpreadsheetDocHelper xSheet.getCellByPosition( 8, 49 ).setFormula( "=Apples+Oranges" ); } -// ________________________________________________________________ + /** Helper for doDatabaseSamples: get name of first database. */ private String getFirstDatabaseName() @@ -1221,7 +1221,7 @@ public class SpreadsheetSample extends SpreadsheetDocHelper System.out.println("can't get database"); } -// ________________________________________________________________ + private void doDataPilotSamples() throws Exception { @@ -1270,7 +1270,7 @@ public class SpreadsheetSample extends SpreadsheetDocHelper xFieldProp.setPropertyValue( "Function", com.sun.star.sheet.GeneralFunction.AVERAGE ); } -// ________________________________________________________________ + private void doFunctionAccessSamples() throws RuntimeException, Exception { @@ -1322,7 +1322,7 @@ public class SpreadsheetSample extends SpreadsheetDocHelper System.out.println(); } -// ________________________________________________________________ + private void doApplicationSettingsSamples() throws RuntimeException, Exception { @@ -1345,6 +1345,6 @@ public class SpreadsheetSample extends SpreadsheetDocHelper System.out.println( aEntries[i] ); } -// ________________________________________________________________ + } diff --git a/odk/examples/DevelopersGuide/Spreadsheet/ViewSample.java b/odk/examples/DevelopersGuide/Spreadsheet/ViewSample.java index 8b4e8afaef10..d522b09cde5a 100644 --- a/odk/examples/DevelopersGuide/Spreadsheet/ViewSample.java +++ b/odk/examples/DevelopersGuide/Spreadsheet/ViewSample.java @@ -41,7 +41,7 @@ import com.sun.star.uno.UnoRuntime; public class ViewSample extends SpreadsheetDocHelper { -// ________________________________________________________________ + public static void main( String args[] ) { @@ -59,14 +59,14 @@ public class ViewSample extends SpreadsheetDocHelper System.exit( 0 ); } -// ________________________________________________________________ + public ViewSample( String[] args ) { super( args ); } -// ________________________________________________________________ + /** This sample function performs all changes on the view. */ public void doSampleFunction() throws Exception @@ -126,7 +126,7 @@ public class ViewSample extends SpreadsheetDocHelper } } -// ________________________________________________________________ + // listener to react on finished selection @@ -156,6 +156,6 @@ public class ViewSample extends SpreadsheetDocHelper } } -// ________________________________________________________________ + } diff --git a/odk/examples/DevelopersGuide/UCB/ChildrenRetriever.java b/odk/examples/DevelopersGuide/UCB/ChildrenRetriever.java index 03a45bae9c23..af37982133f7 100644 --- a/odk/examples/DevelopersGuide/UCB/ChildrenRetriever.java +++ b/odk/examples/DevelopersGuide/UCB/ChildrenRetriever.java @@ -141,9 +141,9 @@ public class ChildrenRetriever { result = new ArrayList<ArrayList<Object>>(); - ///////////////////////////////////////////////////////////////////// + // Iterate over children, access children and property values... - ///////////////////////////////////////////////////////////////////// + // Move to begin. if ( resultSet.first() ) { diff --git a/odk/examples/DevelopersGuide/UCB/DataStreamRetriever.java b/odk/examples/DevelopersGuide/UCB/DataStreamRetriever.java index 84529ab39533..e83a307e3e83 100644 --- a/odk/examples/DevelopersGuide/UCB/DataStreamRetriever.java +++ b/odk/examples/DevelopersGuide/UCB/DataStreamRetriever.java @@ -159,9 +159,9 @@ public class DataStreamRetriever { public void printStream( XInputStream data ) throws com.sun.star.uno.Exception { - ///////////////////////////////////////////////////////////////////// + // Read data from input stream...65536 - ///////////////////////////////////////////////////////////////////// + // Data buffer. Will be allocated by input stream implementation! byte[][] buffer = new byte[ 1 ][ 65536 ]; diff --git a/odk/examples/DevelopersGuide/UCB/Helper.java b/odk/examples/DevelopersGuide/UCB/Helper.java index 7bde0ce47e6e..0a53a2d4d574 100644 --- a/odk/examples/DevelopersGuide/UCB/Helper.java +++ b/odk/examples/DevelopersGuide/UCB/Helper.java @@ -147,17 +147,17 @@ public class Helper { Object executeCommand( XInterface ifc, String commandName, Object argument ) throws com.sun.star.ucb.CommandAbortedException, com.sun.star.uno.Exception { - ///////////////////////////////////////////////////////////////////// + // Obtain command processor interface from given content. - ///////////////////////////////////////////////////////////////////// + XCommandProcessor cmdProcessor = UnoRuntime.queryInterface( XCommandProcessor.class, ifc ); - ///////////////////////////////////////////////////////////////////// + // Assemble command to execute. - ///////////////////////////////////////////////////////////////////// + Command command = new Command(); command.Name = commandName; diff --git a/odk/examples/DevelopersGuide/UCB/ResourceCreator.java b/odk/examples/DevelopersGuide/UCB/ResourceCreator.java index c78710881698..566266246e77 100644 --- a/odk/examples/DevelopersGuide/UCB/ResourceCreator.java +++ b/odk/examples/DevelopersGuide/UCB/ResourceCreator.java @@ -160,9 +160,9 @@ public class ResourceCreator { if ( newContent != null ) { - ///////////////////////////////////////////////////////////////////// + // Set mandatory properties... - ///////////////////////////////////////////////////////////////////// + // Define property value sequence. PropertyValue[] props = new PropertyValue[ 1 ]; @@ -175,9 +175,9 @@ public class ResourceCreator { // Execute command "setPropertyValues". m_helper.executeCommand( newContent, "setPropertyValues", props ); - ///////////////////////////////////////////////////////////////////// + // Write the new file to disk... - ///////////////////////////////////////////////////////////////////// + // Obtain document data for the new file. XInputStream data = stream; diff --git a/odk/examples/DevelopersGuide/UCB/ResourceManager.java b/odk/examples/DevelopersGuide/UCB/ResourceManager.java index eb48a151f2a5..3ab7bbeecd5b 100644 --- a/odk/examples/DevelopersGuide/UCB/ResourceManager.java +++ b/odk/examples/DevelopersGuide/UCB/ResourceManager.java @@ -119,9 +119,9 @@ public class ResourceManager { ( transOperation.equals( "copy" ) || transOperation.equals( "move" ) || transOperation.equals( "link" ))) { - ///////////////////////////////////////////////////////////////////// + // Copy, move or create a link for a resource to another location... - ///////////////////////////////////////////////////////////////////// + GlobalTransferCommandArgument arg = new GlobalTransferCommandArgument(); if ( transOperation.equals( "copy" )) { arg.Operation = TransferCommandOperation.COPY; diff --git a/odk/examples/DevelopersGuide/UCB/ResourceRemover.java b/odk/examples/DevelopersGuide/UCB/ResourceRemover.java index f08740889cdb..560132acbf0e 100644 --- a/odk/examples/DevelopersGuide/UCB/ResourceRemover.java +++ b/odk/examples/DevelopersGuide/UCB/ResourceRemover.java @@ -80,9 +80,9 @@ public class ResourceRemover { boolean result = false; if ( m_content != null ) { - ///////////////////////////////////////////////////////////////////// + // Destroy a resource physically... - ///////////////////////////////////////////////////////////////////// + Boolean deletePhysically = new Boolean( true ); diff --git a/odk/examples/OLE/activex/SOActiveX.cpp b/odk/examples/OLE/activex/SOActiveX.cpp index eedc524e1d45..e264290a6db6 100644 --- a/odk/examples/OLE/activex/SOActiveX.cpp +++ b/odk/examples/OLE/activex/SOActiveX.cpp @@ -59,7 +59,7 @@ OLECHAR* pSlotName[BARS_NUMBER] = -///////////////////////////////////////////////////////////////////////////// + HRESULT ExecuteFunc( IDispatch* idispUnoObject, OLECHAR* sFuncName, @@ -121,7 +121,7 @@ HRESULT PutPropertiesToIDisp( IDispatch* pdispObject, return S_OK; } -///////////////////////////////////////////////////////////////////////////// + // CSOActiveX CSOActiveX::CSOActiveX() @@ -640,6 +640,6 @@ STDMETHODIMP CSOActiveX::Invoke(DISPID dispidMember, return S_OK; } -// --------------------------------------------------------------------------- + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/odk/examples/OLE/activex/SOActiveX.h b/odk/examples/OLE/activex/SOActiveX.h index 3e00dd51facd..f36cbe78a993 100644 --- a/odk/examples/OLE/activex/SOActiveX.h +++ b/odk/examples/OLE/activex/SOActiveX.h @@ -46,7 +46,7 @@ #include "so_activex.h" -///////////////////////////////////////////////////////////////////////////// + // CSOActiveX class ATL_NO_VTABLE CSOActiveX : public CComObjectRootEx<CComSingleThreadModel>, diff --git a/odk/examples/OLE/activex/SOComWindowPeer.cpp b/odk/examples/OLE/activex/SOComWindowPeer.cpp index 6e88bdbcd333..0045014fec81 100644 --- a/odk/examples/OLE/activex/SOComWindowPeer.cpp +++ b/odk/examples/OLE/activex/SOComWindowPeer.cpp @@ -40,8 +40,8 @@ #include "SOComWindowPeer.h" #include <sal/macros.h> -///////////////////////////////////////////////////////////////////////////// -// + + STDMETHODIMP SOComWindowPeer::InterfaceSupportsErrorInfo(REFIID riid) { diff --git a/odk/examples/OLE/activex/SOComWindowPeer.h b/odk/examples/OLE/activex/SOComWindowPeer.h index 29856820bd57..b03b26ca7a61 100644 --- a/odk/examples/OLE/activex/SOComWindowPeer.h +++ b/odk/examples/OLE/activex/SOComWindowPeer.h @@ -34,8 +34,8 @@ *************************************************************************/ // SOComWindowPeer.h: Definition of the SOComWindowPeer class -// -////////////////////////////////////////////////////////////////////// + + #ifndef __SOCOMWINDOWPEER_H_ #define __SOCOMWINDOWPEER_H_ @@ -52,7 +52,7 @@ #include "so_activex.h" -///////////////////////////////////////////////////////////////////////////// + // SOComWindowPeer class SOComWindowPeer : diff --git a/odk/examples/OLE/activex/resource.h b/odk/examples/OLE/activex/resource.h index bf1bf5c7dedc..88480036ff05 100644 --- a/odk/examples/OLE/activex/resource.h +++ b/odk/examples/OLE/activex/resource.h @@ -36,7 +36,7 @@ //{{NO_DEPENDENCIES}} // Microsoft Developer Studio generated include file. // Used by so_activex.rc -// + #define IDS_PROJNAME 100 #define IDB_SOACTIVEX 101 #define IDR_SOACTIVEX 102 @@ -44,7 +44,7 @@ #define IDR_SOCOMWINDOWPEER 104 // Next default values for new objects -// + #ifdef APSTUDIO_INVOKED #ifndef APSTUDIO_READONLY_SYMBOLS #define _APS_NEXT_RESOURCE_VALUE 201 diff --git a/odk/examples/OLE/activex/so_activex.cpp b/odk/examples/OLE/activex/so_activex.cpp index 64349fb34439..e546aeff56ec 100644 --- a/odk/examples/OLE/activex/so_activex.cpp +++ b/odk/examples/OLE/activex/so_activex.cpp @@ -55,7 +55,7 @@ BEGIN_OBJECT_MAP(ObjectMap) OBJECT_ENTRY(CLSID_SOActiveX, CSOActiveX) END_OBJECT_MAP() -///////////////////////////////////////////////////////////////////////////// + // DLL Entry Point extern "C" @@ -71,7 +71,7 @@ BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID /*lpReserved*/) return TRUE; // ok } -///////////////////////////////////////////////////////////////////////////// + // Used to determine whether the DLL can be unloaded by OLE STDAPI DllCanUnloadNow(void) @@ -79,7 +79,7 @@ STDAPI DllCanUnloadNow(void) return (_Module.GetLockCount()==0) ? S_OK : S_FALSE; } -///////////////////////////////////////////////////////////////////////////// + // Returns a class factory to create an object of the requested type STDAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppv) @@ -87,7 +87,7 @@ STDAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppv) return _Module.GetClassObject(rclsid, riid, ppv); } -///////////////////////////////////////////////////////////////////////////// + // DllRegisterServer - Adds entries to the system registry STDAPI DllRegisterServer(void) @@ -97,7 +97,7 @@ STDAPI DllRegisterServer(void) return aResult; } -///////////////////////////////////////////////////////////////////////////// + // DllUnregisterServer - Removes entries from the system registry STDAPI DllUnregisterServer(void) diff --git a/odk/examples/OLE/activex/so_activex.idl b/odk/examples/OLE/activex/so_activex.idl index 9e4c17563045..6013b7e5521d 100644 --- a/odk/examples/OLE/activex/so_activex.idl +++ b/odk/examples/OLE/activex/so_activex.idl @@ -34,7 +34,7 @@ *************************************************************************/ // so_activex.idl : IDL source for so_activex.dll -// + // This file will be processed by the MIDL tool to // produce the type library (so_activex.tlb) and marshalling code. diff --git a/odk/examples/OLE/activex/so_activex.rc b/odk/examples/OLE/activex/so_activex.rc index 72ca32e1a72c..1141e104422d 100644 --- a/odk/examples/OLE/activex/so_activex.rc +++ b/odk/examples/OLE/activex/so_activex.rc @@ -33,20 +33,20 @@ *************************************************************************/ //Microsoft Developer Studio generated resource script. -// + #include "resource.h" #define APSTUDIO_READONLY_SYMBOLS -///////////////////////////////////////////////////////////////////////////// -// + + // Generated from the TEXTINCLUDE 2 resource. -// + #include "winres.h" -///////////////////////////////////////////////////////////////////////////// + #undef APSTUDIO_READONLY_SYMBOLS -///////////////////////////////////////////////////////////////////////////// + // Russian resources //#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_RUS) @@ -55,26 +55,26 @@ //#pragma code_page(1251) //#endif //_WIN32 -///////////////////////////////////////////////////////////////////////////// -// + + // Bitmap -// + //IDB_SOACTIVEX BITMAP DISCARDABLE "soacti.bmp" -///////////////////////////////////////////////////////////////////////////// -// + + // REGISTRY -// + IDR_SOACTIVEX REGISTRY DISCARDABLE "SOActiveX.rgs" IDR_SOCOMWINDOWPEER REGISTRY DISCARDABLE "SOComWindowPeer.rgs" //#endif // Russian resources -///////////////////////////////////////////////////////////////////////////// -///////////////////////////////////////////////////////////////////////////// + + // English (U.S.) resources #if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) @@ -84,10 +84,10 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US #endif //_WIN32 #ifdef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// + + // TEXTINCLUDE -// + 1 TEXTINCLUDE DISCARDABLE BEGIN @@ -108,10 +108,10 @@ END #endif // APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// + + // String Table -// + STRINGTABLE DISCARDABLE BEGIN @@ -119,18 +119,18 @@ BEGIN END #endif // English (U.S.) resources -///////////////////////////////////////////////////////////////////////////// + #ifndef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// + + // Generated from the TEXTINCLUDE 3 resource. -// + 1 TYPELIB .\..\..\..\WINexample.out\misc\so_activex\so_activex.tlb -///////////////////////////////////////////////////////////////////////////// + #endif // not APSTUDIO_INVOKED diff --git a/odk/examples/cpp/DocumentLoader/DocumentLoader.cxx b/odk/examples/cpp/DocumentLoader/DocumentLoader.cxx index 0fae160a15a9..77c3c2bc7eb7 100644 --- a/odk/examples/cpp/DocumentLoader/DocumentLoader.cxx +++ b/odk/examples/cpp/DocumentLoader/DocumentLoader.cxx @@ -70,7 +70,7 @@ using namespace com::sun::star::registry; using ::rtl::OUString; using ::rtl::OUStringToOString; -//============================================================================ + SAL_IMPLEMENT_MAIN_WITH_ARGS(argc, argv) { OUString sConnectionString("uno:socket,host=localhost,port=2083;urp;StarOffice.ServiceManager"); diff --git a/odk/examples/cpp/counter/counter.cxx b/odk/examples/cpp/counter/counter.cxx index 9fc6326a466f..227092a58d3f 100644 --- a/odk/examples/cpp/counter/counter.cxx +++ b/odk/examples/cpp/counter/counter.cxx @@ -148,9 +148,9 @@ Reference< XInterface > SAL_CALL MyCounterImpl_create( } -//######################################################################### + //#### EXPORTED ########################################################### -//######################################################################### + /** * This function is called to get service factories for an implementation. diff --git a/odk/examples/cpp/counter/countermain.cxx b/odk/examples/cpp/counter/countermain.cxx index 6cbde3a278f2..2c510d9cc931 100644 --- a/odk/examples/cpp/counter/countermain.cxx +++ b/odk/examples/cpp/counter/countermain.cxx @@ -67,7 +67,7 @@ using namespace com::sun::star::lang; using namespace ::rtl; -//======================================================================= + SAL_IMPLEMENT_MAIN() { try { diff --git a/odk/examples/cpp/custompanel/ctp_factory.cxx b/odk/examples/cpp/custompanel/ctp_factory.cxx index 7ff959a47586..febde8dbf944 100644 --- a/odk/examples/cpp/custompanel/ctp_factory.cxx +++ b/odk/examples/cpp/custompanel/ctp_factory.cxx @@ -48,9 +48,9 @@ namespace sd { namespace colortoolpanel using ::com::sun::star::container::NoSuchElementException; using ::com::sun::star::awt::XWindow; - //================================================================================================================== + //= ToolPanelFactory - //================================================================================================================== + ToolPanelFactory::ToolPanelFactory( const Reference< XComponentContext >& i_rContext ) :m_xContext( i_rContext ) @@ -133,8 +133,8 @@ namespace sd { namespace colortoolpanel return *( new ToolPanelFactory( i_rContext ) ); } -//...................................................................................................................... + } } // namespace sd::colortoolpanel -//...................................................................................................................... + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/odk/examples/cpp/custompanel/ctp_factory.hxx b/odk/examples/cpp/custompanel/ctp_factory.hxx index 2399807b2106..09894068ce39 100644 --- a/odk/examples/cpp/custompanel/ctp_factory.hxx +++ b/odk/examples/cpp/custompanel/ctp_factory.hxx @@ -27,14 +27,14 @@ #include <cppuhelper/implbase2.hxx> #include <cppuhelper/basemutex.hxx> -//...................................................................................................................... + namespace sd { namespace colortoolpanel { -//...................................................................................................................... - //================================================================================================================== + + //= ToolPanelFactory - //================================================================================================================== + typedef ::cppu::WeakImplHelper2 < ::com::sun::star::ui::XUIElementFactory , ::com::sun::star::lang::XServiceInfo > ToolPanelFactory_Base; @@ -65,9 +65,9 @@ namespace sd { namespace colortoolpanel m_xContext; }; -//...................................................................................................................... + } } // namespace sd::colortoolpanel -//...................................................................................................................... + #endif // SD_WORKBENCH_CTP_FACTORY_HXX diff --git a/odk/examples/cpp/custompanel/ctp_panel.cxx b/odk/examples/cpp/custompanel/ctp_panel.cxx index e486de7e4d79..78b68635470a 100644 --- a/odk/examples/cpp/custompanel/ctp_panel.cxx +++ b/odk/examples/cpp/custompanel/ctp_panel.cxx @@ -32,10 +32,10 @@ #include <osl/diagnose.h> -//...................................................................................................................... + namespace sd { namespace colortoolpanel { -//...................................................................................................................... + using ::com::sun::star::uno::Reference; using ::com::sun::star::uno::XInterface; @@ -68,9 +68,9 @@ namespace sd { namespace colortoolpanel namespace PosSize = ::com::sun::star::awt::PosSize; namespace UIElementType = ::com::sun::star::ui::UIElementType; - //================================================================================================================== + //= helpers - //================================================================================================================== + namespace { Reference< XWindow > lcl_createPlainWindow_nothrow( const Reference< XComponentContext >& i_rContext, @@ -97,9 +97,9 @@ namespace sd { namespace colortoolpanel return NULL; } } - //================================================================================================================== + //= class SingleColorPanel - //================================================================================================================== + SingleColorPanel::SingleColorPanel( const Reference< XComponentContext >& i_rContext, const Reference< XWindow >& i_rParentWindow, const ::sal_Int32 i_nPanelColor ) :SingleColorPanel_Base( m_aMutex ) @@ -195,9 +195,9 @@ namespace sd { namespace colortoolpanel m_xWindow.clear(); } - //================================================================================================================== + //= PanelUIElement - //================================================================================================================== + PanelUIElement::PanelUIElement( const Reference< XComponentContext >& i_rContext, const Reference< XWindow >& i_rParentWindow, const OUString& i_rResourceURL, const ::sal_Int32 i_nPanelColor ) @@ -248,8 +248,8 @@ namespace sd { namespace colortoolpanel xPanelComponent->dispose(); } -//...................................................................................................................... + } } // namespace sd::colortoolpanel -//...................................................................................................................... + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/odk/examples/cpp/custompanel/ctp_panel.hxx b/odk/examples/cpp/custompanel/ctp_panel.hxx index 8ef6aa5fc6e5..1e9566990105 100644 --- a/odk/examples/cpp/custompanel/ctp_panel.hxx +++ b/odk/examples/cpp/custompanel/ctp_panel.hxx @@ -31,14 +31,14 @@ #include <cppuhelper/basemutex.hxx> -//...................................................................................................................... + namespace sd { namespace colortoolpanel { -//...................................................................................................................... - //================================================================================================================== + + //= SingleColorPanel - //================================================================================================================== + typedef ::cppu::WeakComponentImplHelper2 < ::com::sun::star::ui::XToolPanel , ::com::sun::star::awt::XPaintListener > SingleColorPanel_Base; @@ -73,9 +73,9 @@ namespace sd { namespace colortoolpanel const sal_Int32 m_nPanelColor; }; - //================================================================================================================== + //= PanelUIElement - //================================================================================================================== + typedef ::cppu::WeakComponentImplHelper1 < ::com::sun::star::ui::XUIElement > PanelUIElement_Base; class PanelUIElement :public ::cppu::BaseMutex @@ -107,9 +107,9 @@ namespace sd { namespace colortoolpanel m_xToolPanel; }; -//...................................................................................................................... + } } // namespace sd::colortoolpanel -//...................................................................................................................... + #endif // SD_WORKBENCH_CTP_PANEL_HXX diff --git a/odk/examples/cpp/custompanel/ctp_services.cxx b/odk/examples/cpp/custompanel/ctp_services.cxx index d67dddd1aa81..4b96e2b14e55 100644 --- a/odk/examples/cpp/custompanel/ctp_services.cxx +++ b/odk/examples/cpp/custompanel/ctp_services.cxx @@ -22,15 +22,15 @@ #include <cppuhelper/implementationentry.hxx> #include <uno/lbnames.h> -//...................................................................................................................... + namespace sd { namespace colortoolpanel { -//...................................................................................................................... - //================================================================================================================== + + //= descriptors for the services implemented in this component - //================================================================================================================== + static struct ::cppu::ImplementationEntry s_aServiceEntries[] = { { @@ -42,9 +42,9 @@ namespace sd { namespace colortoolpanel { 0, 0, 0, 0, 0, 0 } }; -//...................................................................................................................... + } } // namespace sd::colortoolpanel -//...................................................................................................................... + extern "C" { diff --git a/odk/examples/java/Drawing/SDraw.java b/odk/examples/java/Drawing/SDraw.java index a935b0d08c71..1e41d3679aee 100644 --- a/odk/examples/java/Drawing/SDraw.java +++ b/odk/examples/java/Drawing/SDraw.java @@ -32,11 +32,11 @@ * *************************************************************************/ -//*************************************************************************** + // comment: Step 1: bootstrap UNO and get the remote component context // Step 2: open an empty text document // Step 3: get the drawpage an insert some shapes -//*************************************************************************** + import java.lang.Math; @@ -51,7 +51,7 @@ public class SDraw { //oooooooooooooooooooooooooooStep 1oooooooooooooooooooooooooooooooooooooooo // bootstrap UNO and get the remote component context. The context can // be used to get the service manager - //************************************************************************* + com.sun.star.uno.XComponentContext xContext = null; try { @@ -72,7 +72,7 @@ public class SDraw { // For this purpose an instance of com.sun.star.frame.Desktop // is created. It's interface XDesktop provides the XComponentLoader, // which is used to open the document via loadComponentFromURL - //************************************************************************* + //Open document //Draw @@ -85,7 +85,7 @@ public class SDraw { // To add a shape get the MultiServiceFaktory of the document, create an // instance of the ShapeType and add it to the Shapes-container // provided by the drawpage - //************************************************************************* + // get the drawpage of drawing here @@ -115,7 +115,7 @@ public class SDraw { xShapes.add(createShape(xDrawDoc,3000,4500,15000,1000,"Ellipse",16711680)); xShapes.add(createShape(xDrawDoc,5000,3500,7500,5000,"Rectangle",6710932)); - //************************************************************************* + System.out.println("done"); System.exit(0); } diff --git a/odk/examples/java/EmbedDocument/EmbeddedObject/OwnEmbeddedObject.java b/odk/examples/java/EmbedDocument/EmbeddedObject/OwnEmbeddedObject.java index 3ae069560838..644903ea00c4 100644 --- a/odk/examples/java/EmbedDocument/EmbeddedObject/OwnEmbeddedObject.java +++ b/odk/examples/java/EmbedDocument/EmbeddedObject/OwnEmbeddedObject.java @@ -65,7 +65,7 @@ public final class OwnEmbeddedObject extends WeakBase Dimension m_aObjSize; - // ------------------------------------------------------------- + protected ArrayList<Object> GetListeners() { if ( m_aListeners == null ) @@ -74,7 +74,7 @@ public final class OwnEmbeddedObject extends WeakBase return m_aListeners; } - // ------------------------------------------------------------- + protected Dimension UpdateSizeAndGetFromActive() { if ( m_nObjectState == com.sun.star.embed.EmbedStates.ACTIVE ) @@ -86,7 +86,7 @@ public final class OwnEmbeddedObject extends WeakBase return new Dimension(); } - // ------------------------------------------------------------- + protected void SwitchOwnPersistence( XStorage xParentStorage, XStorage xOwnStorage, String aEntryName ) { if ( xOwnStorage != m_xOwnStorage ) @@ -99,7 +99,7 @@ public final class OwnEmbeddedObject extends WeakBase } } - // ------------------------------------------------------------- + protected void SwitchOwnPersistence( XStorage xParentStorage, String aEntryName ) throws com.sun.star.io.IOException { if ( xParentStorage != m_xParentStorage || !aEntryName.equals( m_aEntryName ) ) @@ -124,7 +124,7 @@ public final class OwnEmbeddedObject extends WeakBase } } - // ------------------------------------------------------------- + protected static void SaveDataToStorage( XStorage xStorage, String aString, Dimension aDimension ) throws com.sun.star.io.IOException { try @@ -184,7 +184,7 @@ public final class OwnEmbeddedObject extends WeakBase } } - // ------------------------------------------------------------- + protected void PostEvent( String aEvEntryName ) { if ( m_aListeners != null ) @@ -207,7 +207,7 @@ public final class OwnEmbeddedObject extends WeakBase } } - // ------------------------------------------------------------- + protected void StateChangeNotification( boolean bBeforeChange, int nOldState, int nNewState ) { if ( m_aListeners != null ) @@ -235,7 +235,7 @@ public final class OwnEmbeddedObject extends WeakBase } } - // ------------------------------------------------------------- + protected String ReadStringFromStream( XStorage xStorage, String aStreamName ) throws com.sun.star.io.IOException { if ( xStorage == null ) @@ -280,7 +280,7 @@ public final class OwnEmbeddedObject extends WeakBase } } - // ------------------------------------------------------------- + protected void ReadSizeFromOwnStorage() throws com.sun.star.io.IOException { String aSize = ReadStringFromStream( m_xOwnStorage, "properties.txt" ); @@ -294,14 +294,14 @@ public final class OwnEmbeddedObject extends WeakBase } } - // ------------------------------------------------------------- + public OwnEmbeddedObject( XComponentContext context, byte[] aClassID ) { m_xContext = context; m_aClassID = aClassID; }; - // ------------------------------------------------------------- + public void CloseFrameRequest() { com.sun.star.embed.XEmbeddedClient xClient = m_xClient; @@ -326,7 +326,7 @@ public final class OwnEmbeddedObject extends WeakBase } // com.sun.star.embed.XCommonEmbedPersist: - // ------------------------------------------------------------- + public void storeOwn() throws com.sun.star.embed.WrongStateException, com.sun.star.io.IOException, com.sun.star.uno.Exception { if ( m_bDisposed ) @@ -352,13 +352,13 @@ public final class OwnEmbeddedObject extends WeakBase PostEvent( "OnSaveDone" ); } - // ------------------------------------------------------------- + public boolean isReadonly() throws com.sun.star.embed.WrongStateException { return false; } - // ------------------------------------------------------------- + public void reload(com.sun.star.beans.PropertyValue[] aMediaArgs, com.sun.star.beans.PropertyValue[] aObjectArgs) throws com.sun.star.lang.IllegalArgumentException, com.sun.star.embed.WrongStateException, com.sun.star.io.IOException, com.sun.star.uno.Exception { // not implemented currently @@ -366,7 +366,7 @@ public final class OwnEmbeddedObject extends WeakBase } // com.sun.star.embed.XEmbedPersist: - // ------------------------------------------------------------- + public void setPersistentEntry(com.sun.star.embed.XStorage xStorage, String aEntryName, int nEntryConnectionMode, com.sun.star.beans.PropertyValue[] aMediaArgs, com.sun.star.beans.PropertyValue[] aObjectArgs) throws com.sun.star.lang.IllegalArgumentException, com.sun.star.embed.WrongStateException, com.sun.star.io.IOException, com.sun.star.uno.Exception { if ( m_bDisposed ) @@ -439,7 +439,7 @@ public final class OwnEmbeddedObject extends WeakBase throw new com.sun.star.lang.IllegalArgumentException(); } - // ------------------------------------------------------------- + public void storeToEntry(com.sun.star.embed.XStorage xStorage, String aEntryName, com.sun.star.beans.PropertyValue[] aMediaArgs, com.sun.star.beans.PropertyValue[] aObjectArgs) throws com.sun.star.lang.IllegalArgumentException, com.sun.star.embed.WrongStateException, com.sun.star.io.IOException, com.sun.star.uno.Exception { if ( m_bDisposed ) @@ -464,7 +464,7 @@ public final class OwnEmbeddedObject extends WeakBase } } - // ------------------------------------------------------------- + public void storeAsEntry(com.sun.star.embed.XStorage xStorage, String aEntryName, com.sun.star.beans.PropertyValue[] aMediaArgs, com.sun.star.beans.PropertyValue[] aObjectArgs) throws com.sun.star.lang.IllegalArgumentException, com.sun.star.embed.WrongStateException, com.sun.star.io.IOException, com.sun.star.uno.Exception { if ( m_bDisposed ) @@ -499,7 +499,7 @@ public final class OwnEmbeddedObject extends WeakBase } - // ------------------------------------------------------------- + public void saveCompleted(boolean bUseNew) throws com.sun.star.embed.WrongStateException, com.sun.star.uno.Exception { if ( m_bDisposed ) @@ -536,7 +536,7 @@ public final class OwnEmbeddedObject extends WeakBase m_bWaitSaveCompleted = false; } - // ------------------------------------------------------------- + public boolean hasEntry() throws com.sun.star.embed.WrongStateException { if ( m_bDisposed ) @@ -551,7 +551,7 @@ public final class OwnEmbeddedObject extends WeakBase return false; } - // ------------------------------------------------------------- + public String getEntryName() throws com.sun.star.embed.WrongStateException { if ( m_bDisposed ) @@ -564,7 +564,7 @@ public final class OwnEmbeddedObject extends WeakBase } // com.sun.star.embed.XVisualObject: - // ------------------------------------------------------------- + public void setVisualAreaSize(long nAspect, com.sun.star.awt.Size aSize) throws com.sun.star.lang.IllegalArgumentException, com.sun.star.embed.WrongStateException, com.sun.star.uno.Exception { if ( m_bDisposed ) @@ -587,7 +587,7 @@ public final class OwnEmbeddedObject extends WeakBase m_aEditorFrame.setAppSize( m_aObjSize ); } - // ------------------------------------------------------------- + public com.sun.star.awt.Size getVisualAreaSize(long nAspect) throws com.sun.star.lang.IllegalArgumentException, com.sun.star.embed.WrongStateException, com.sun.star.uno.Exception { if ( m_bDisposed ) @@ -608,7 +608,7 @@ public final class OwnEmbeddedObject extends WeakBase return new com.sun.star.awt.Size( (int)m_aObjSize.getWidth(), (int)m_aObjSize.getHeight() ); } - // ------------------------------------------------------------- + public VisualRepresentation getPreferredVisualRepresentation(long nAspect) throws com.sun.star.lang.IllegalArgumentException, com.sun.star.embed.WrongStateException, com.sun.star.uno.Exception { if ( m_bDisposed ) @@ -631,7 +631,7 @@ public final class OwnEmbeddedObject extends WeakBase return aVisRep; } - // ------------------------------------------------------------- + public int getMapUnit(long nAspect) throws com.sun.star.uno.Exception { if ( m_bDisposed ) @@ -648,7 +648,7 @@ public final class OwnEmbeddedObject extends WeakBase } // com.sun.star.embed.XClassifiedObject: - // ------------------------------------------------------------- + public byte[] getClassID() { if ( m_bDisposed ) @@ -657,7 +657,7 @@ public final class OwnEmbeddedObject extends WeakBase return m_aClassID; } - // ------------------------------------------------------------- + public String getClassName() { if ( m_bDisposed ) @@ -666,14 +666,14 @@ public final class OwnEmbeddedObject extends WeakBase return new String(); } - // ------------------------------------------------------------- + public void setClassInfo(byte[] aClassID, String sClassName) throws com.sun.star.lang.NoSupportException { throw new com.sun.star.lang.NoSupportException(); } // com.sun.star.embed.XComponentSupplier: - // ------------------------------------------------------------- + public com.sun.star.util.XCloseable getComponent() { if ( m_bDisposed ) @@ -684,7 +684,7 @@ public final class OwnEmbeddedObject extends WeakBase } // com.sun.star.embed.XStateChangeBroadcaster: - // ------------------------------------------------------------- + public void addStateChangeListener(com.sun.star.embed.XStateChangeListener xListener) { if ( m_bDisposed ) @@ -693,7 +693,7 @@ public final class OwnEmbeddedObject extends WeakBase GetListeners().add( xListener ); } - // ------------------------------------------------------------- + public void removeStateChangeListener(com.sun.star.embed.XStateChangeListener xListener) { if ( m_bDisposed ) @@ -704,7 +704,7 @@ public final class OwnEmbeddedObject extends WeakBase } // com.sun.star.document.XEventBroadcaster: - // ------------------------------------------------------------- + public void addEventListener(com.sun.star.document.XEventListener xListener) { if ( m_bDisposed ) @@ -713,7 +713,7 @@ public final class OwnEmbeddedObject extends WeakBase GetListeners().add( xListener ); } - // ------------------------------------------------------------- + public void removeEventListener(com.sun.star.document.XEventListener xListener) { if ( m_bDisposed ) @@ -724,7 +724,7 @@ public final class OwnEmbeddedObject extends WeakBase } // com.sun.star.util.XCloseBroadcaster: - // ------------------------------------------------------------- + public void addCloseListener(com.sun.star.util.XCloseListener xListener) { if ( m_bDisposed ) @@ -733,7 +733,7 @@ public final class OwnEmbeddedObject extends WeakBase GetListeners().add( xListener ); } - // ------------------------------------------------------------- + public void removeCloseListener(com.sun.star.util.XCloseListener xListener) { if ( m_bDisposed ) @@ -744,7 +744,7 @@ public final class OwnEmbeddedObject extends WeakBase } // com.sun.star.util.XCloseable: - // ------------------------------------------------------------- + public void close(boolean bDeliverOwnership) throws com.sun.star.util.CloseVetoException { if ( m_bDisposed ) @@ -813,7 +813,7 @@ public final class OwnEmbeddedObject extends WeakBase } // com.sun.star.embed.XEmbeddedObject: - // ------------------------------------------------------------- + public void changeState(int nNewState) throws com.sun.star.embed.UnreachableStateException, com.sun.star.embed.WrongStateException, com.sun.star.uno.Exception { if ( m_bDisposed ) @@ -928,7 +928,7 @@ public final class OwnEmbeddedObject extends WeakBase StateChangeNotification( true, nOldState, nNewState ); } - // ------------------------------------------------------------- + public int[] getReachableStates() throws com.sun.star.embed.NeedsRunningStateException, com.sun.star.embed.WrongStateException { if ( m_bDisposed ) @@ -945,7 +945,7 @@ public final class OwnEmbeddedObject extends WeakBase return pStates; } - // ------------------------------------------------------------- + public int getCurrentState() throws com.sun.star.embed.WrongStateException { if ( m_bDisposed ) @@ -957,7 +957,7 @@ public final class OwnEmbeddedObject extends WeakBase return m_nObjectState; } - // ------------------------------------------------------------- + public void doVerb(int nVerbID) throws com.sun.star.lang.IllegalArgumentException, com.sun.star.embed.WrongStateException, com.sun.star.embed.UnreachableStateException, com.sun.star.uno.Exception { if ( m_bDisposed ) @@ -974,7 +974,7 @@ public final class OwnEmbeddedObject extends WeakBase changeState( com.sun.star.embed.EmbedStates.RUNNING ); } - // ------------------------------------------------------------- + public com.sun.star.embed.VerbDescriptor[] getSupportedVerbs() throws com.sun.star.embed.NeedsRunningStateException, com.sun.star.embed.WrongStateException { if ( m_bDisposed ) @@ -1058,7 +1058,7 @@ public final class OwnEmbeddedObject extends WeakBase return new com.sun.star.embed.VerbDescriptor[0]; } - // ------------------------------------------------------------- + public void setClientSite(com.sun.star.embed.XEmbeddedClient xClient) throws com.sun.star.embed.WrongStateException { if ( m_bDisposed ) @@ -1070,7 +1070,7 @@ public final class OwnEmbeddedObject extends WeakBase m_xClient = xClient; } - // ------------------------------------------------------------- + public com.sun.star.embed.XEmbeddedClient getClientSite() throws com.sun.star.embed.WrongStateException { if ( m_bDisposed ) @@ -1082,7 +1082,7 @@ public final class OwnEmbeddedObject extends WeakBase return m_xClient; } - // ------------------------------------------------------------- + public void update() throws com.sun.star.embed.WrongStateException, com.sun.star.uno.Exception { if ( m_bDisposed ) @@ -1094,7 +1094,7 @@ public final class OwnEmbeddedObject extends WeakBase // not implemented } - // ------------------------------------------------------------- + public void setUpdateMode(int nMode) throws com.sun.star.embed.WrongStateException { if ( m_bDisposed ) @@ -1106,7 +1106,7 @@ public final class OwnEmbeddedObject extends WeakBase // not implemented } - // ------------------------------------------------------------- + public long getStatus(long nAspect) throws com.sun.star.embed.WrongStateException { if ( m_bDisposed ) @@ -1118,7 +1118,7 @@ public final class OwnEmbeddedObject extends WeakBase return 0; } - // ------------------------------------------------------------- + public void setContainerName(String sName) { if ( m_bDisposed ) diff --git a/odk/examples/java/Inspector/InspectorAddon.java b/odk/examples/java/Inspector/InspectorAddon.java index d5ec16811fc7..6ca6c4260438 100644 --- a/odk/examples/java/Inspector/InspectorAddon.java +++ b/odk/examples/java/Inspector/InspectorAddon.java @@ -221,6 +221,6 @@ public class InspectorAddon { } // __create( XComponentContext ){ -// + // } } diff --git a/odk/examples/java/Spreadsheet/EuroAdaption.java b/odk/examples/java/Spreadsheet/EuroAdaption.java index 51b419df5d92..8168aee4f1a4 100644 --- a/odk/examples/java/Spreadsheet/EuroAdaption.java +++ b/odk/examples/java/Spreadsheet/EuroAdaption.java @@ -32,13 +32,13 @@ * *************************************************************************/ -//*************************************************************************** + // comment: Step 1: get the Desktop object from the office // Step 2: open an empty Calc document // Step 3: enter a example text, set the numberformat to DM // Step 4: change the numberformat to EUR (Euro) // Step 5: use the DM/EUR factor on each cell with a content -//*************************************************************************** + import com.sun.star.beans.PropertyValue; import com.sun.star.beans.XPropertySet; diff --git a/odk/examples/java/Spreadsheet/SCalc.java b/odk/examples/java/Spreadsheet/SCalc.java index dded8243fa7e..51c869e6eec8 100644 --- a/odk/examples/java/Spreadsheet/SCalc.java +++ b/odk/examples/java/Spreadsheet/SCalc.java @@ -32,14 +32,14 @@ * *************************************************************************/ -//*************************************************************************** + // comment: Step 1: get the remote component context from the office // Step 2: open an empty calc document // Step 3: create cell styles // Step 4: get the sheet an insert some data // Step 5: apply the created cell syles // Step 6: insert a 3D Chart -//*************************************************************************** + import com.sun.star.awt.Rectangle; @@ -87,7 +87,7 @@ public class SCalc { //oooooooooooooooooooooooooooStep 1oooooooooooooooooooooooooooooooooooooooooo // call UNO bootstrap method and get the remote component context form // the a running office (office will be started if necessary) - //*************************************************************************** + XComponentContext xContext = null; // get the remote office component context @@ -104,7 +104,7 @@ public class SCalc { // For this purpose an instance of com.sun.star.frame.Desktop // is created. The desktop provides the XComponentLoader interface, // which is used to open the document via loadComponentFromURL - //*************************************************************************** + //Open document @@ -115,7 +115,7 @@ public class SCalc { System.out.println("Opening an empty Calc document"); myDoc = openCalc(xContext); - //*************************************************************************** + //oooooooooooooooooooooooooooStep 3oooooooooooooooooooooooooooooooooooooooooo @@ -123,7 +123,7 @@ public class SCalc { // For this purpose get the StyleFamiliesSupplier and the familiy // CellStyle. Create an instance of com.sun.star.style.CellStyle and // add it to the family. Now change some properties - //*************************************************************************** + try { XStyleFamiliesSupplier xSFS = UnoRuntime.queryInterface(XStyleFamiliesSupplier.class, myDoc); @@ -152,7 +152,7 @@ public class SCalc { e.printStackTrace(System.err); } - //*************************************************************************** + //oooooooooooooooooooooooooooStep 4oooooooooooooooooooooooooooooooooooooooooo // get the sheet an insert some data. @@ -160,7 +160,7 @@ public class SCalc { // Now some data can be inserted. For this purpose get a Cell via // getCellByPosition and insert into this cell via setValue() (for floats) // or setFormula() for formulas and Strings - //*************************************************************************** + XSpreadsheet xSheet=null; @@ -245,20 +245,20 @@ public class SCalc { insertIntoCell(12,3,"38.5",xSheet,"V"); insertIntoCell(13,3,"=SUM(A4:L4)",xSheet,""); - //*************************************************************************** + //oooooooooooooooooooooooooooStep 5oooooooooooooooooooooooooooooooooooooooooo // apply the created cell style. // For this purpose get the PropertySet of the Cell and change the // property CellStyle to the appropriate value. - //*************************************************************************** + // change backcolor chgbColor( 1 , 0, 13, 0, "My Style", xSheet ); chgbColor( 0 , 1, 0, 3, "My Style", xSheet ); chgbColor( 1 , 1, 13, 3, "My Style2", xSheet ); - //*************************************************************************** + //oooooooooooooooooooooooooooStep 6oooooooooooooooooooooooooooooooooooooooooo // insert a 3D chart. @@ -267,7 +267,7 @@ public class SCalc { // add a new chart based on the data to the TableCharts. // get the ChartDocument, which provide the Diagramm. Change the properties // Dim3D (3 dimension) and String (the title) of the diagramm. - //*************************************************************************** + // insert a chart diff --git a/odk/examples/java/Storage/Test01.java b/odk/examples/java/Storage/Test01.java index 4abe4b25b83c..43be8cce1af0 100644 --- a/odk/examples/java/Storage/Test01.java +++ b/odk/examples/java/Storage/Test01.java @@ -114,9 +114,9 @@ public class Test01 implements StorageTest { if ( !m_aTestHelper.disposeStorage( xTempStorage ) || !m_aTestHelper.disposeStorage( xTempFileStorage ) ) return false; - // ================================================ + // now check all the written and copied information - // ================================================ + // the temporary file must not be locked any more after storage disposing pArgs[1] = new Integer( ElementModes.READWRITE ); diff --git a/odk/examples/java/Storage/Test02.java b/odk/examples/java/Storage/Test02.java index c78260b95bc1..10fda47a713a 100644 --- a/odk/examples/java/Storage/Test02.java +++ b/odk/examples/java/Storage/Test02.java @@ -104,9 +104,9 @@ public class Test02 implements StorageTest { return false; - // ================================================ + // now check all the written information - // ================================================ + // close the output part of the temporary stream // the output part must present since we already wrote to the stream diff --git a/odk/examples/java/Storage/Test03.java b/odk/examples/java/Storage/Test03.java index fe9d8c05c499..2d8802eb3f37 100644 --- a/odk/examples/java/Storage/Test03.java +++ b/odk/examples/java/Storage/Test03.java @@ -85,9 +85,9 @@ public class Test03 implements StorageTest { if ( !m_aTestHelper.disposeStorage( xTempSubStorage ) ) return false; - // ================================================ + // check storage hyerarchy tree - // ================================================ + // check that isStorageElement() and isStreamElement reacts to nonexisting object correctly try { diff --git a/odk/examples/java/Storage/Test04.java b/odk/examples/java/Storage/Test04.java index 9196b3870c23..9be3c528ec8e 100644 --- a/odk/examples/java/Storage/Test04.java +++ b/odk/examples/java/Storage/Test04.java @@ -171,9 +171,9 @@ public class Test04 implements StorageTest { if ( !m_aTestHelper.disposeStorage( xTempStorage ) || !m_aTestHelper.disposeStorage( xTempFileStorage ) ) return false; - // ================================================ + // now check all the written and copied information - // ================================================ + // the temporary file must not be locked any more after storage disposing pArgs[1] = new Integer( ElementModes.READWRITE ); diff --git a/odk/examples/java/Storage/Test05.java b/odk/examples/java/Storage/Test05.java index 15f37b9661a8..2bb865620010 100644 --- a/odk/examples/java/Storage/Test05.java +++ b/odk/examples/java/Storage/Test05.java @@ -210,9 +210,9 @@ public class Test05 implements StorageTest { return false; - // ================================================ + // now check all the written and copied information - // ================================================ + pArgs[1] = new Integer( ElementModes.READ ); Object oResultStorage = m_xStorageFactory.createInstanceWithArguments( pArgs ); diff --git a/odk/examples/java/Storage/Test07.java b/odk/examples/java/Storage/Test07.java index 2e24b3c126b5..4e11fadbc855 100644 --- a/odk/examples/java/Storage/Test07.java +++ b/odk/examples/java/Storage/Test07.java @@ -92,9 +92,9 @@ public class Test07 implements StorageTest { if ( !m_aTestHelper.disposeStorage( xTempStorage ) || !m_aTestHelper.disposeStorage( xTempFileStorage ) ) return false; - // ================================================ + // now check all the written and copied information - // ================================================ + // the temporary file must not be locked any more after storage disposing pArgs[1] = new Integer( ElementModes.READWRITE ); diff --git a/odk/examples/java/Storage/Test08.java b/odk/examples/java/Storage/Test08.java index 4aef187901cc..e36780a07aed 100644 --- a/odk/examples/java/Storage/Test08.java +++ b/odk/examples/java/Storage/Test08.java @@ -147,9 +147,9 @@ public class Test08 implements StorageTest { if ( !m_aTestHelper.disposeStorage( xTempStorage ) || !m_aTestHelper.disposeStorage( xTempFileStorage ) ) return false; - // ================================================ + // now check all the written and copied information - // ================================================ + // the temporary file must not be locked any more after storage disposing pArgs[1] = new Integer( ElementModes.READ ); diff --git a/odk/examples/java/Storage/Test09.java b/odk/examples/java/Storage/Test09.java index 2c0fbac71950..0a8a365eebab 100644 --- a/odk/examples/java/Storage/Test09.java +++ b/odk/examples/java/Storage/Test09.java @@ -99,9 +99,9 @@ public class Test09 implements StorageTest { if ( !m_aTestHelper.disposeStorage( xTempStorage ) || !m_aTestHelper.disposeStorage( xTempFileStorage ) ) return false; - // ================================================ + // now check all the written and copied information - // ================================================ + // the temporary file must not be locked any more after storage disposing pArgs[1] = new Integer( ElementModes.READ ); diff --git a/odk/examples/java/Text/BookmarkInsertion.java b/odk/examples/java/Text/BookmarkInsertion.java index fee990dc653c..71cadb4b0594 100644 --- a/odk/examples/java/Text/BookmarkInsertion.java +++ b/odk/examples/java/Text/BookmarkInsertion.java @@ -32,14 +32,14 @@ * *************************************************************************/ -//*************************************************************************** + // comment: Step 1: get the Desktop object from the office // Step 2: open an empty text document // Step 3: enter a example text // Step 4: insert some bookmarks -// + // Chapter 5.1.1.4 Inserting bookmarks -//*************************************************************************** + import com.sun.star.uno.UnoRuntime; diff --git a/odk/examples/java/Text/HardFormatting.java b/odk/examples/java/Text/HardFormatting.java index bcd40262e6f4..62fa3a55ae1d 100644 --- a/odk/examples/java/Text/HardFormatting.java +++ b/odk/examples/java/Text/HardFormatting.java @@ -32,15 +32,15 @@ * *************************************************************************/ -//*************************************************************************** + // comment: Step 1: get the Desktop object from the office // Step 2: open an empty text document // Step 3: enter a example text // Step 4: get some text attributes // Step 5: check the PropertyState from the selection -// + // Chapter 4.1.4 Hard formatting -//*************************************************************************** + import com.sun.star.uno.UnoRuntime; diff --git a/odk/examples/java/Text/SWriter.java b/odk/examples/java/Text/SWriter.java index 7b79bc817997..0256324743ec 100644 --- a/odk/examples/java/Text/SWriter.java +++ b/odk/examples/java/Text/SWriter.java @@ -32,14 +32,14 @@ * *************************************************************************/ -//*************************************************************************** + // comment: Step 1: bootstrap UNO and get the remote component context // Step 2: open an empty text document // Step 3: enter some text // Step 4: insert a text table // Step 5: insert colored text // Step 6: insert a text frame -//*************************************************************************** + import com.sun.star.uno.UnoRuntime; @@ -51,7 +51,7 @@ public class SWriter { //oooooooooooooooooooooooooooStep 1oooooooooooooooooooooooooooooooooooooooo // bootstrap UNO and get the remote component context. The context can // be used to get the service manager - //************************************************************************* + com.sun.star.uno.XComponentContext xContext = null; try { @@ -70,14 +70,14 @@ public class SWriter { // For this purpose an instance of com.sun.star.frame.Desktop // is created. It's interface XDesktop provides the XComponentLoader, // which is used to open the document via loadComponentFromURL - //************************************************************************* + //Open Writer document System.out.println("Opening an empty Writer document"); com.sun.star.text.XTextDocument myDoc = openWriter(xContext); - //************************************************************************* + //oooooooooooooooooooooooooooStep 3oooooooooooooooooooooooooooooooooooooooo @@ -85,7 +85,7 @@ public class SWriter { // For this purpose get the Text-Object of the document an create the // cursor. Now it is possible to insert a text at the cursor-position // via insertString - //************************************************************************* + //getting the text object @@ -100,7 +100,7 @@ public class SWriter { //inserting a second line xText.insertString( xTCursor, "Now we're in the second line\n", false ); - //************************************************************************* + //oooooooooooooooooooooooooooStep 4oooooooooooooooooooooooooooooooooooooooo @@ -109,7 +109,7 @@ public class SWriter { // instance of com.sun.star.text.TextTable and initialize it. Now it can // be inserted at the cursor position via insertTextContent. // After that some properties are changed and some data is inserted. - //************************************************************************* + //inserting a text table System.out.println("Inserting a text table"); @@ -197,7 +197,7 @@ public class SWriter { // insert a colored text. // Get the propertySet of the cursor, change the CharColor and add a // shadow. Then insert the Text via InsertString at the cursor position. - //************************************************************************* + // get the property set of the cursor com.sun.star.beans.XPropertySet xTCPS = UnoRuntime.queryInterface(com.sun.star.beans.XPropertySet.class, @@ -246,7 +246,7 @@ public class SWriter { // document. Change some properties an insert it. // Now get the text-Object of the frame an the corresponding cursor. // Insert some text via insertString. - //************************************************************************* + // Create a TextFrame com.sun.star.text.XTextFrame xTF = null; diff --git a/odk/examples/java/Text/StyleCreation.java b/odk/examples/java/Text/StyleCreation.java index f32b6672dfae..4c9643514d24 100644 --- a/odk/examples/java/Text/StyleCreation.java +++ b/odk/examples/java/Text/StyleCreation.java @@ -32,14 +32,14 @@ * *************************************************************************/ -//*************************************************************************** + // comment: Step 1: get the Desktop object from the office // Step 2: open an empty text document // Step 3: create a new Paragraph style // Step 4: apply the Paragraph style -// + // Chapter 4.1.3 Defining Your Own Style -//*************************************************************************** + import com.sun.star.uno.UnoRuntime; diff --git a/odk/examples/java/Text/StyleInitialization.java b/odk/examples/java/Text/StyleInitialization.java index 21e0f9bf2bc3..5acf7559d673 100644 --- a/odk/examples/java/Text/StyleInitialization.java +++ b/odk/examples/java/Text/StyleInitialization.java @@ -32,13 +32,13 @@ * *************************************************************************/ -//*************************************************************************** + // comment: Step 1: get the Desktop object from the office // Step 2: open an empty text document // Step 3: enter a example text // Step 4: use the paragraph collection // Step 5: apply a different paragraph style on the paragraphs -//*************************************************************************** + import com.sun.star.uno.UnoRuntime; import com.sun.star.uno.AnyConverter; diff --git a/odk/examples/java/Text/TextDocumentStructure.java b/odk/examples/java/Text/TextDocumentStructure.java index 74b2659ac9ee..1880dffd8458 100644 --- a/odk/examples/java/Text/TextDocumentStructure.java +++ b/odk/examples/java/Text/TextDocumentStructure.java @@ -32,12 +32,12 @@ * *************************************************************************/ -//*************************************************************************** + // comment: Step 1: bootstrap UNO and get the remote component context // Step 2: open an empty text document // Step 3: create an enumeration of all paragraphs // Step 4: create an enumeration of all text portions -//*************************************************************************** + import com.sun.star.uno.UnoRuntime; diff --git a/odk/examples/java/Text/TextReplace.java b/odk/examples/java/Text/TextReplace.java index 86ce7a4d2e18..b23cfb971982 100644 --- a/odk/examples/java/Text/TextReplace.java +++ b/odk/examples/java/Text/TextReplace.java @@ -32,12 +32,12 @@ * *************************************************************************/ -//*************************************************************************** + // comment: Step 1: get the Desktop object from the office // Step 2: open an empty text document // Step 3: enter a example text // Step 4: replace some english spelled words with US spelled -//*************************************************************************** + import com.sun.star.uno.UnoRuntime; |