Package org.zkoss.zss.engine

Examples of org.zkoss.zss.engine.Ref


      DrawingManager dm = ((SheetCtrl)_sheet).getDrawingManager();
      dm.movePicture(_sheet, picture, anchor);
      final RangeImpl rng = (RangeImpl) Ranges.range(_sheet, anchor.getRow1(), anchor.getCol1(), anchor.getRow2(), anchor.getCol2());
      final Collection<Ref> refs = rng.getRefs();
      if (refs != null && !refs.isEmpty()) {
        final Ref ref = refs.iterator().next();
        BookHelper.notifyPictureUpdate(ref, picture);
      }
    }
  }
View Full Code Here


      DrawingManager dm = ((SheetCtrl)_sheet).getDrawingManager();
      dm.moveChart(_sheet, chart, anchor);
      final RangeImpl rng = (RangeImpl) Ranges.range(_sheet, anchor.getRow1(), anchor.getCol1(), anchor.getRow2(), anchor.getCol2());
      final Collection<Ref> refs = rng.getRefs();
      if (refs != null && !refs.isEmpty()) {
        final Ref ref = refs.iterator().next();
        BookHelper.notifyChartUpdate(ref, chart);
      }
    }
  }
View Full Code Here

      ClientAnchor anchor = chart.getPreferredSize();
      final RangeImpl rng = (RangeImpl) Ranges.range(_sheet, anchor.getRow1(), anchor.getCol1(), anchor.getRow2(), anchor.getCol2());
      final Collection<Ref> refs = rng.getRefs();
      dm.deleteChart(_sheet, chart); //must after getPreferredSize() or anchor is gone!
      if (refs != null && !refs.isEmpty()) {
        final Ref ref = refs.iterator().next();
        BookHelper.notifyChartDelete(ref, chart);
      }
    }
  }
View Full Code Here

    }
  }

  @Override
  public void notifyMoveFriendFocus(Object token) {
    Ref ref = _refs != null && !_refs.isEmpty() ? _refs.iterator().next() : null;
    if (ref != null) {
      BookHelper.notifyMoveFriendFocus(ref, token);
    }
  }
View Full Code Here

    }
  }

  @Override
  public void notifyDeleteFriendFocus(Object token) {
    Ref ref = _refs != null && !_refs.isEmpty() ? _refs.iterator().next() : null;
    if (ref != null) {
      BookHelper.notifyDeleteFriendFocus(ref, token);
    }
  }
View Full Code Here

  }
 
  @Override
  public void createSheet(String name) {
    synchronized (_sheet.getBook()) {
      Ref ref = _refs != null && !_refs.isEmpty() ? _refs.iterator().next() : null;
      if (ref != null) {
        final Book book = _sheet.getBook();
        if (book != null) {
          if (Strings.isBlank(name)) {
            book.createSheet();
View Full Code Here

  }

  @Override
  public void setSheetName(String name) {
    synchronized (_sheet.getBook()) {
      Ref ref = _refs != null && !_refs.isEmpty() ? _refs.iterator().next() : null;
      if (ref != null) {
        final Book book = _sheet.getBook();
        if (book != null) {
          if (!Strings.isBlank(name)) {
            final int pos= book.getSheetIndex(_sheet);
View Full Code Here

  }
 
  @Override
  public void setSheetOrder(int pos) {
    synchronized (_sheet.getBook()) {
      Ref ref = _refs != null && !_refs.isEmpty() ? _refs.iterator().next() : null;
      if (ref != null) {
        final Book book = _sheet.getBook();
        if (book != null) {
          final String name = _sheet.getSheetName();
          if (!Strings.isBlank(name)) {
View Full Code Here

  }

  @Override
  public void deleteSheet() {
    synchronized (_sheet.getBook()) {
      Ref ref = _refs != null && !_refs.isEmpty() ? _refs.iterator().next() : null;
      if (ref != null) {
        final Book book = _sheet.getBook();
        if (book != null) {
          final int index = book.getSheetIndex(_sheet);
          if (index != -1) {
View Full Code Here

    }
  }

  @Override
  public boolean isCustomHeight() {
    Ref ref = _refs != null && !_refs.isEmpty() ? _refs.iterator().next() : null;
    if (ref != null) {
      final int tRow = ref.getTopRow();
      final RefSheet refSheet = ref.getOwnerSheet();
      final Row row = getRow(tRow, refSheet);
      if (row != null) {
        return row.isCustomHeight();
      }
    }
View Full Code Here

TOP

Related Classes of org.zkoss.zss.engine.Ref

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.