Rect setEmpty - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Rect setEmpty method.

This code example shows how to use the following methods:isEmpty, set, setEmpty
                stopBlink(); 
 
                mSelectedCell = cell;
                mSelectedValue = state;
                mBlinkDisplayOff = false;
                mBlinkRect.set(MARGIN + x * sxy, MARGIN + y * sxy,
                               MARGIN + (x + 1) * sxy, MARGIN + (y + 1) * sxy);
 
                if (state != State.EMPTY) {
                    // Start the blinker 
                    mHandler.sendEmptyMessageDelayed(MSG_BLINK, FPS_MS);
                } 
 
                if (mCellListener != null) {
                    mCellListener.onCellSelected();
                } 
            } 
 
            return true; 
        } 

7
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:isEmpty, set, setEmpty
				hlRect.set(v.getLeft(), v.getTop(),
						v.getRight(), v.getBottom());
				return; 
			} 
		} 
		hlRect.setEmpty();
	} 
	 
	@Override 
	protected void dispatchDraw(Canvas canvas) {
		Drawable d = hlDrawable;
		if (hlPosition != -1 && d != null) {
			updateHighlightRect(); 
			if (!hlRect.isEmpty()) {
				canvas.save();
				canvas.clipRect(hlRect);
				d.draw(canvas);
				canvas.restore();
			} 
		} 
6
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:setEmpty
 
    @Override 
    protected void onSizeChanged(int w, int h, int oldw, int oldh) {
        super.onSizeChanged(w, h, oldw, oldh);
 
        mFrameBounds.setEmpty();
    } 
 
    public void setOverlay(int overlayId) {
        if (overlayId >= 0) {
            mOverlay = getResources().getDrawable(overlayId);
            mFrameBounds.setEmpty();
        } else { 
            mOverlay = null;
        } 
    } 
} 
5
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:set, setEmpty
		invalidate();
	} 
 
	private void computeBitmapSize(Rect rect) {
		if (null != rect) {
			bitmapFrame.set(rect);
		} 
		if (null != mBitmap) {
			if (rect.right == 0 && rect.bottom == 0) {
				final Rect r = bitmapFrame;
				r.set(r.left, r.top,
						r.left + mBitmap.getScaledHeight(mTargetDentity), r.top
								+ mBitmap.getScaledHeight(mTargetDentity));
			} 
		} else { 
			bitmapFrame.setEmpty();
		} 
	} 
 
	private void measureAndSplitText(Paint p, String content, int maxWidth) {
		FontMetrics fm = mPaint.getFontMetrics();
5
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:setEmpty
 
        Drawable background = getBackground();
        if (background != null) {
            background.getPadding(r);
        } else { 
            r.setEmpty();
        } 
 
        int height = (getHeight() - r.top - r.bottom) / this.count;
        textPaint.setTextSize(height * 0.5f);
 
        for (int i = 0; i < this.count; i++) {
            final float rate = values[i] / values[0];
            drawSingle(canvas, i, rate, r.left, r.top + i * height, getWidth()
                    - r.right, r.top + (i + 1) * height);
        } 
    } 
 
    private void drawSingle(Canvas canvas, int i, float rate, int left,
            int top, int right, int bottom) {
4
CodeRank
Experience pair programming with AI  Get Codota for Java

Related Rect setEmpty Questions & Answers:

setEmpty Method Overview
Set the rectangle to (0,0,0,0)
See Code Examples for other Android Rect Methods: