summaryrefslogtreecommitdiff
path: root/android/src/com/artifex/mupdf/BitmapHolder.java
blob: 4e1edf63e19f89006977ab4d8f8e7872cc3119ae (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
package com.artifex.mupdf;

import android.graphics.Bitmap;

public class BitmapHolder {
	private Bitmap bm;

	public BitmapHolder() {
		bm = null;
	}

	public synchronized void setBm(Bitmap abm) {
		if (bm != null && bm != abm)
			bm.recycle();
		bm = abm;
	}

	public synchronized Bitmap getBm() {
		return bm;
	}
}