]>
iEval git - fonbot.git/blob - src/ro/ieval/fonbot/FonBotApplication.java
1 package ro
.ieval
.fonbot
;
3 import android
.app
.Application
;
4 import android
.content
.Intent
;
5 import android
.telephony
.PhoneStateListener
;
6 import android
.telephony
.TelephonyManager
;
9 * Copyright © 2013 Marius Gavrilescu
11 * This file is part of FonBot.
13 * FonBot is free software: you can redistribute it and/or modify
14 * it under the terms of the GNU General Public License as published by
15 * the Free Software Foundation, either version 3 of the License, or
16 * (at your option) any later version.
18 * FonBot is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU General Public License for more details.
23 * You should have received a copy of the GNU General Public License
24 * along with FonBot. If not, see <http://www.gnu.org/licenses/>.
28 * The {@link Application} class of FonBot. Registers the device with GCM, starts the TTS service and keeps global state.
30 * @author Marius Gavrilescu <marius@ieval.ro>
32 public final class FonBotApplication
extends Application
{
36 public static final String GCM_SENDER_ID
= "379674287523";
39 public void onCreate() {
42 final TelephonyManager tman
=(TelephonyManager
) getSystemService(TELEPHONY_SERVICE
);
43 tman
.listen(new FonBotPhoneStateListener(this), PhoneStateListener
.LISTEN_CALL_STATE
);
45 startService(new Intent(this, FonBotMainService
.class));
47 // Thread.setDefaultUncaughtExceptionHandler(new RemoteCrashdumpHandler(this));
This page took 0.041402 seconds and 4 git commands to generate.