Calculator Overlay
This commit is contained in:
parent
75b60e7390
commit
85feb7cfef
@ -53,6 +53,17 @@
|
|||||||
|
|
||||||
<!-- OVERLAY CONFIG -->
|
<!-- OVERLAY CONFIG -->
|
||||||
|
|
||||||
|
<activity android:launchMode="singleInstance"
|
||||||
|
android:label="@string/c_app_name_on_screen"
|
||||||
|
android:name=".CalculatorOnScreenStartActivity">
|
||||||
|
|
||||||
|
<intent-filter>
|
||||||
|
<action android:name="android.intent.action.MAIN"/>
|
||||||
|
<category android:name="android.intent.category.LAUNCHER"/>
|
||||||
|
</intent-filter>
|
||||||
|
|
||||||
|
</activity>
|
||||||
|
|
||||||
<service android:name=".overlay.CalculatorOverlayService">
|
<service android:name=".overlay.CalculatorOverlayService">
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
<action android:name="org.solovyev.calculator.widget.EDITOR_STATE_CHANGED"/>
|
<action android:name="org.solovyev.calculator.widget.EDITOR_STATE_CHANGED"/>
|
||||||
|
@ -8,6 +8,7 @@
|
|||||||
|
|
||||||
<resources>
|
<resources>
|
||||||
<string name="c_app_name">Calculator++</string>
|
<string name="c_app_name">Calculator++</string>
|
||||||
|
<string name="c_app_name_on_screen">Calculator++ (On Screen)</string>
|
||||||
<string name="c_app_name_free">Calculator++ Free</string>
|
<string name="c_app_name_free">Calculator++ Free</string>
|
||||||
<string name="c_app_icon_name">Calc++</string>
|
<string name="c_app_icon_name">Calc++</string>
|
||||||
<string name="c_app_settings">Settings</string>
|
<string name="c_app_settings">Settings</string>
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
package org.solovyev.android.calculator;
|
package org.solovyev.android.calculator;
|
||||||
|
|
||||||
import android.content.Intent;
|
|
||||||
import android.content.SharedPreferences;
|
import android.content.SharedPreferences;
|
||||||
import android.preference.PreferenceManager;
|
import android.preference.PreferenceManager;
|
||||||
import net.robotmedia.billing.BillingController;
|
import net.robotmedia.billing.BillingController;
|
||||||
@ -14,7 +13,6 @@ import org.solovyev.android.ads.AdsController;
|
|||||||
import org.solovyev.android.calculator.external.AndroidExternalListenersContainer;
|
import org.solovyev.android.calculator.external.AndroidExternalListenersContainer;
|
||||||
import org.solovyev.android.calculator.history.AndroidCalculatorHistory;
|
import org.solovyev.android.calculator.history.AndroidCalculatorHistory;
|
||||||
import org.solovyev.android.calculator.model.AndroidCalculatorEngine;
|
import org.solovyev.android.calculator.model.AndroidCalculatorEngine;
|
||||||
import org.solovyev.android.calculator.overlay.CalculatorOverlayService;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* User: serso
|
* User: serso
|
||||||
@ -117,8 +115,6 @@ public class CalculatorApplication extends android.app.Application {
|
|||||||
public void run() {
|
public void run() {
|
||||||
BillingController.checkBillingSupported(CalculatorApplication.this);
|
BillingController.checkBillingSupported(CalculatorApplication.this);
|
||||||
AdsController.getInstance().isAdFree(CalculatorApplication.this);
|
AdsController.getInstance().isAdFree(CalculatorApplication.this);
|
||||||
|
|
||||||
startService(new Intent(getApplicationContext(), CalculatorOverlayService.class));
|
|
||||||
}
|
}
|
||||||
}).start();
|
}).start();
|
||||||
|
|
||||||
|
@ -0,0 +1,18 @@
|
|||||||
|
package org.solovyev.android.calculator;
|
||||||
|
|
||||||
|
import android.app.Activity;
|
||||||
|
import android.content.Intent;
|
||||||
|
import android.os.Bundle;
|
||||||
|
import org.solovyev.android.calculator.overlay.CalculatorOverlayService;
|
||||||
|
|
||||||
|
public class CalculatorOnScreenStartActivity extends Activity {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onCreate(Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
|
||||||
|
startService(new Intent(this, CalculatorOverlayService.class));
|
||||||
|
|
||||||
|
this.finish();
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user