本文整理匯總了Java中org.geometerplus.android.fbreader.api.ApiListener類的典型用法代碼示例。如果您正苦於以下問題:Java ApiListener類的具體用法?Java ApiListener怎麽用?Java ApiListener使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
ApiListener類屬於org.geometerplus.android.fbreader.api包,在下文中一共展示了ApiListener類的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: onResume
import org.geometerplus.android.fbreader.api.ApiListener; //導入依賴的package包/類
@Override
protected void onResume()
{
super.onResume();
myStartTimer = true;
final int brightnessLevel = getZLibrary().ScreenBrightnessLevelOption.getValue();
if (brightnessLevel != 0)
{
setScreenBrightness(brightnessLevel);
}
else
{
setScreenBrightnessAuto();
}
if (getZLibrary().DisableButtonLightsOption.getValue())
{
setButtonLight(false);
}
registerReceiver(myBatteryInfoReceiver, new IntentFilter(Intent.ACTION_BATTERY_CHANGED));
PopupPanel.restoreVisibilities(myFBReaderApp);
ApiServerImplementation.sendEvent(this, ApiListener.EVENT_READ_MODE_OPENED);
getCollection().bindToService(this, new Runnable()
{
public void run()
{
final BookModel model = myFBReaderApp.Model;
if (model == null || model.Book == null) { return; }
onPreferencesUpdate(myFBReaderApp.Collection.getBookById(model.Book.getId()));
}
});
}
示例2: onStop
import org.geometerplus.android.fbreader.api.ApiListener; //導入依賴的package包/類
@Override
protected void onStop()
{
ApiServerImplementation.sendEvent(this, ApiListener.EVENT_READ_MODE_CLOSED);
PopupPanel.removeAllWindows(myFBReaderApp, this);
super.onStop();
}
示例3: onResume
import org.geometerplus.android.fbreader.api.ApiListener; //導入依賴的package包/類
@Override
protected void onResume() {
super.onResume();
myStartTimer = true;
final int brightnessLevel = getZLibrary().ScreenBrightnessLevelOption
.getValue();
if (brightnessLevel != 0) {
setScreenBrightness(brightnessLevel);
} else {
setScreenBrightnessAuto();
}
if (getZLibrary().DisableButtonLightsOption.getValue()) {
setButtonLight(false);
}
registerReceiver(myBatteryInfoReceiver, new IntentFilter(
Intent.ACTION_BATTERY_CHANGED));
PopupPanel.restoreVisibilities(myFBReaderApp);
ApiServerImplementation.sendEvent(this,
ApiListener.EVENT_READ_MODE_OPENED);
getCollection().bindToService(this, new Runnable() {
public void run() {
final BookModel model = myFBReaderApp.Model;
if (model == null || model.Book == null) {
return;
}
onPreferencesUpdate(myFBReaderApp.Collection
.getBookById(model.Book.getId()));
}
});
}
示例4: onStop
import org.geometerplus.android.fbreader.api.ApiListener; //導入依賴的package包/類
@Override
protected void onStop() {
ApiServerImplementation.sendEvent(this,
ApiListener.EVENT_READ_MODE_CLOSED);
PopupPanel.removeAllWindows(myFBReaderApp, this);
Log.i("MAIN", "onStop()");
super.onStop();
}