This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# add the webupd8team java PPA | |
sudo apt-get install software-properties-common python-software-properties | |
sudo add-apt-repository ppa:webupd8team/java | |
sudo apt-get update | |
# install oracle java 6 | |
sudo apt-get install oracle-java6-installer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private GeoPoint center; | |
private int zoomLevel = -1; | |
@Override | |
public void onPause() { | |
super.onPause(); | |
center = mapView.getMapCenter(); | |
zoomLevel = mapView.getZoomLevel(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
A_IMPORT="import com.amazon.geo.maps" | |
G_IMPORT="import com.google.android.maps" | |
A_VIEW="com.amazon.geo.maps.MapView" | |
G_VIEW="com.google.android.maps.MapView" | |
if [ "$1" = "a" ]; then | |
FR=$G_IMPORT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- fixes for broken Holo text appearances on Kindle Fire 2/HD --> | |
<style name="TextAppearance.KindleFix.Small" parent="android:TextAppearance" > | |
<item name="android:textSize">14sp</item> | |
<item name="android:textColor">?android:attr/textColorSecondary</item> | |
</style> | |
<style name="TextAppearance.KindleFix.Small.Inverse" > | |
<item name="android:textColor">?android:attr/textColorSecondaryInverse</item> | |
<item name="android:textColorHint">?android:attr/textColorHintInverse</item> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.readystatesoftware.views; | |
import android.content.Context; | |
import android.graphics.Rect; | |
import android.util.AttributeSet; | |
import android.widget.LinearLayout; | |
public class FittingLinearLayout extends LinearLayout { | |
public FittingLinearLayout(Context context, AttributeSet attrs, int defStyle) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/******************************************************************************* | |
* Copyright 2011, 2012 Chris Banes. 2013 readyState Software Ltd. | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Copyright (C) 2013 readyState Software Ltd | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private Notification buildNotification() { | |
NotificationCompat.Builder builder = new NotificationCompat.Builder(context) | |
.setCategory(NotificationCompat.CATEGORY_EVENT) | |
.setVisibility(NotificationCompat.VISIBILITY_PRIVATE) // default | |
.setContentTitle(title) | |
.setContentText(shortText) | |
.setStyle(new NotificationCompat.BigTextStyle().bigText(fullText)) | |
.setSmallIcon(R.drawable.ic_stat_notification) | |
.setColor(context.getResources().getColor(R.color.my_color)) | |
.setContentIntent(intent); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Copyright (C) 2013 The Android Open Source Project | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.example.scalpeldrawer; | |
import android.app.Activity; | |
import android.content.Context; | |
import android.support.v4.widget.DrawerLayout; | |
import android.util.AttributeSet; | |
import android.view.LayoutInflater; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.widget.CheckBox; |
OlderNewer