org.zkoss.zssex.ui.widget
Class DefaultBookWidgetLoader

java.lang.Object
  extended by org.zkoss.zssex.ui.widget.DefaultBookWidgetLoader
All Implemented Interfaces:
WidgetLoader

public class DefaultBookWidgetLoader
extends java.lang.Object
implements WidgetLoader

Author:
Dennis.Chen

Constructor Summary
DefaultBookWidgetLoader()
           
 
Method Summary
 void addChartWidget(SSheet sheet, SChart chart)
          call when spreadsheet try to load a block of cell to client side.
 void addPictureWidget(SSheet sheet, SPicture picture)
           
 void deleteChartWidget(SSheet sheet, java.lang.String chartId)
           
 void deletePictureWidget(SSheet sheet, java.lang.String pictureId)
           
 void init(Spreadsheet spreadsheet)
          Initial a widget loader with a spreadsheet
 void invalidate()
          indicate the spreadsheet is invalidated.
protected  Widget newChartWidget(SSheet sheet, SChart chart, java.lang.String panel, int zindex)
           
protected  java.util.List<Widget> newChartWidgetGroup(SSheet sheet, SChart chart, int zindex)
           
protected  Widget newImageWidget(SSheet sheet, SPicture picture, org.zkoss.image.Image image, java.lang.String panel, int zindex)
           
protected  java.util.List<Widget> newImageWidgetGroup(SSheet sheet, SPicture picture, int zindex)
           
 void onColumnChange(SSheet sheet, int left, int right)
           
 void onRowChange(SSheet sheet, int top, int bottom)
           
 void onSheetClean(SSheet sheet)
          indicate the sheet is dis-selected
 void onSheetFreeze(SSheet sheet)
          indicate the sheet's freeze panel is changed.
 void onSheetSelected(SSheet sheet)
          indicate the selected sheet of a spreadsheet is changed.
 void updateChartWidget(SSheet sheet, SChart chart)
           
 void updatePictureWidget(SSheet sheet, SPicture picture)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultBookWidgetLoader

public DefaultBookWidgetLoader()
Method Detail

init

public void init(Spreadsheet spreadsheet)
Description copied from interface: WidgetLoader
Initial a widget loader with a spreadsheet

Specified by:
init in interface WidgetLoader

invalidate

public void invalidate()
Description copied from interface: WidgetLoader
indicate the spreadsheet is invalidated.

Specified by:
invalidate in interface WidgetLoader

onSheetClean

public void onSheetClean(SSheet sheet)
Description copied from interface: WidgetLoader
indicate the sheet is dis-selected

Specified by:
onSheetClean in interface WidgetLoader

onSheetSelected

public void onSheetSelected(SSheet sheet)
Description copied from interface: WidgetLoader
indicate the selected sheet of a spreadsheet is changed.

Specified by:
onSheetSelected in interface WidgetLoader

onSheetFreeze

public void onSheetFreeze(SSheet sheet)
Description copied from interface: WidgetLoader
indicate the sheet's freeze panel is changed.

Specified by:
onSheetFreeze in interface WidgetLoader

onColumnChange

public void onColumnChange(SSheet sheet,
                           int left,
                           int right)
Specified by:
onColumnChange in interface WidgetLoader

onRowChange

public void onRowChange(SSheet sheet,
                        int top,
                        int bottom)
Specified by:
onRowChange in interface WidgetLoader

addChartWidget

public void addChartWidget(SSheet sheet,
                           SChart chart)
Description copied from interface: WidgetLoader
call when spreadsheet try to load a block of cell to client side. handler should take care this method and load corresponding widgets, which in the block , to client side. this method will be invoked by spreadsheet, you should not call this method directly.

Specified by:
addChartWidget in interface WidgetLoader

addPictureWidget

public void addPictureWidget(SSheet sheet,
                             SPicture picture)
Specified by:
addPictureWidget in interface WidgetLoader

deletePictureWidget

public void deletePictureWidget(SSheet sheet,
                                java.lang.String pictureId)
Specified by:
deletePictureWidget in interface WidgetLoader

updatePictureWidget

public void updatePictureWidget(SSheet sheet,
                                SPicture picture)
Specified by:
updatePictureWidget in interface WidgetLoader

newImageWidgetGroup

protected java.util.List<Widget> newImageWidgetGroup(SSheet sheet,
                                                     SPicture picture,
                                                     int zindex)

newImageWidget

protected Widget newImageWidget(SSheet sheet,
                                SPicture picture,
                                org.zkoss.image.Image image,
                                java.lang.String panel,
                                int zindex)

newChartWidgetGroup

protected java.util.List<Widget> newChartWidgetGroup(SSheet sheet,
                                                     SChart chart,
                                                     int zindex)
                                              throws java.io.IOException
Throws:
java.io.IOException

newChartWidget

protected Widget newChartWidget(SSheet sheet,
                                SChart chart,
                                java.lang.String panel,
                                int zindex)

updateChartWidget

public void updateChartWidget(SSheet sheet,
                              SChart chart)
Specified by:
updateChartWidget in interface WidgetLoader

deleteChartWidget

public void deleteChartWidget(SSheet sheet,
                              java.lang.String chartId)
Specified by:
deleteChartWidget in interface WidgetLoader


Copyright © 2005-2010 Potix Corporation. All Rights Reserved.