package org.gdg.frisbee.android.activity;

import android.content.Intent;
import android.content.SharedPreferences;
import android.os.Bundle;
import android.support.v7.app.ActionBarActivity;
import android.text.TextUtils;
import android.widget.Toast;

import org.gdg.frisbee.android.BuildConfig;
import org.gdg.frisbee.android.Const;
import org.gdg.frisbee.android.R;

/**
 * Created with IntelliJ IDEA.
 * User: maui
 * Date: 02.07.13
 * Time: 00:03
 * To change this template use File | Settings | File Templates.
 */
public class StartActivity extends ActionBarActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        if (BuildConfig.DEBUG && TextUtils.isEmpty(getString(R.string.play_app_id))) {
            Toast.makeText(this, "no API keys defined!", Toast.LENGTH_SHORT).show();
        }

        SharedPreferences preferences = getSharedPreferences("gdg", MODE_PRIVATE);

        Intent intentForStart;
        if (preferences.getBoolean(Const.SETTINGS_FIRST_START, true)) {
            intentForStart = new Intent(StartActivity.this, FirstStartActivity.class);
        } else {
            intentForStart = new Intent(StartActivity.this, MainActivity.class);
        }

        startActivity(intentForStart);
        finish();
    }
}

@@ -1,8 +1,618 @@
+/*%0A * Copyright 2013-2015 The GDG Frisbee Project%0A *%0A * Licensed under the Apache License, Version 2.0 (the %22License%22);%0A * you may not use this file except in compliance with the License.%0A * You may obtain a copy of the License at%0A *%0A * %09http://www.apache.org/licenses/LICENSE-2.0%0A *%0A * Unless required by applicable law or agreed to in writing, software%0A * distributed under the License is distributed on an %22AS IS%22 BASIS,%0A * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.%0A * See the License for the specific language governing permissions and%0A * limitations under the License.%0A */%0A%0A
 package 
@@ -976,159 +976,8 @@
 R;%0A%0A
-/**%0A * Created with IntelliJ IDEA.%0A * User: maui%0A * Date: 02.07.13%0A * Time: 00:03%0A * To change this template use File %7C Settings %7C File Templates.%0A */%0A
 publ
@@ -1767,16 +1767,17 @@
 nish();%0A
-
     %7D%0A
+%0A
 %7D%0A

remove useless Javadoc and add copyright