void moveActiveRegionTo(Object trigger_owner, int left, int top) { int dx = left - _ar.l; int dy = top - _ar.t; // we just re-calculate all!!! Rect tmpR = _rectA; // till now, we only consider "l, t" value. D2d.fill(_pixels, _sw, _sh, _bgcolor, 0, 0, _sw, _sh); // erase all. tmpR.set(left, top, _ar.r + dx, _ar.b + dy); _compensateThickness(tmpR, WConstants.LIMIT_THICK); _sheet.draw(_pixels, _sw, _sh, left, top, tmpR.l, tmpR.t, tmpR.r, tmpR.b, _zf()); _ar.offset(dx, dy); _rar.offset(dx, dy); _platboard.invalidatePlatBoard(); if (null != _activie_region_moved_listener) _activie_region_moved_listener.onMoved( trigger_owner, _ar.l / (float) _sheet.width(), _ar.t / (float) _sheet.height(), _ar.r / (float) _sheet.width(), _ar.b / (float) _sheet.height()); }
void invalidateBoard(int left, int top, int right, int bottom) { getInvalidateArea(_tmpR, left, top, right, bottom, (byte) _s2c(WConstants.LIMIT_THICK)); _platboard.invalidatePlatBoard(_tmpR); }