Original transcript: http://allisonrandal.com/2012/04/15/open-source-enlightenment/
這幾年來,我慢慢覺得,我們參與開源社群,就像是在一條道路上並肩而行:這不僅讓我們成為更好的程式設計者,也讓我們通過與人合作,而成為更好的人。
您可以將它想成一條修行之道,讓身而為人的我們能夠不斷成長。接下來,我想談談我對開源世界的個人觀點,希望能與您分享。
首先,人是一切開源專案的核心。程式碼是很重要,但最核心的永遠是人。
--- ./frameworks/base/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java~ 2011-11-15 08:04:40.000000000 +0800 | |
+++ ./frameworks/base/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java 2011-11-23 11:26:00.781355800 +0800 | |
@@ -1472,6 +1472,9 @@ | |
loadBooleanSetting(stmt, Settings.Secure.TOUCH_EXPLORATION_ENABLED, | |
R.bool.def_touch_exploration_enabled); | |
+ | |
+ loadBooleanSetting(stmt, Settings.Secure.NETSTATS_ENABLED, | |
+ R.bool.def_netstats_enabled); | |
} finally { |
--- activity.cpp.old 2011-12-17 19:24:35.339670212 +0800 | |
+++ activity.cpp 2011-12-17 19:18:13.427670430 +0800 | |
@@ -75,6 +75,10 @@ | |
// added in eclair rev 7 | |
data.writeInt32(0); | |
} | |
+ if (sdk_version >= 15) { | |
+ // added in IceCreamSandwich 4.0.3 | |
+ data.writeInt32(0); /* Selector */ | |
+ } |
Original transcript: http://allisonrandal.com/2012/04/15/open-source-enlightenment/
這幾年來,我慢慢覺得,我們參與開源社群,就像是在一條道路上並肩而行:這不僅讓我們成為更好的程式設計者,也讓我們通過與人合作,而成為更好的人。
您可以將它想成一條修行之道,讓身而為人的我們能夠不斷成長。接下來,我想談談我對開源世界的個人觀點,希望能與您分享。
首先,人是一切開源專案的核心。程式碼是很重要,但最核心的永遠是人。
mRootContainer = (RelativeLayout) findViewById(R.id.root_container); | |
ViewTreeObserver vto = mRootContainer.getViewTreeObserver(); | |
vto.addOnGlobalLayoutListener(new ViewTreeObserver.OnGlobalLayoutListener() { | |
@Override | |
public void onGlobalLayout() { | |
// get current window size | |
int newWidth = mRootContainer.getWidth(); | |
int newHeight = mRootContainer.getHeight(); |
Redirect /path_to_redirect market://details?id=com.example.package |
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("fb://profile/<id>")); | |
List<ResolveInfo> activities = getPackageManager().queryIntentActivities(intent, 0); | |
if (activities.size() != 0) { | |
startActivity(intent); | |
} else { | |
intent.setData(Uri.parse("https://www.facebook.com/<你的專頁名稱>")); | |
startActivity(intent); | |
} |
[[email protected]:~ ] | |
$ cd /usr/local/ | |
[[email protected]:~ ] | |
$ brew versions gradle | |
1.4 git checkout 0b7303a /usr/local/Library/Formula/gradle.rb | |
1.3 git checkout c259bda /usr/local/Library/Formula/gradle.rb | |
1.2 git checkout 9b7d294 /usr/local/Library/Formula/gradle.rb | |
1.1 git checkout 7941972 /usr/local/Library/Formula/gradle.rb | |
1.0 git checkout dff67fb /usr/local/Library/Formula/gradle.rb | |
1.0-rc-3 git checkout 5f9e348 /usr/local/Library/Formula/gradle.rb |
buildscript { | |
repositories { | |
mavenCentral() | |
} | |
dependencies { | |
classpath 'com.android.tools.build:gradle:0.5.+' | |
} | |
} | |
apply plugin: 'android' |
import android.content.Context; | |
import android.content.res.TypedArray; | |
import android.graphics.Canvas; | |
import android.graphics.Rect; | |
import android.graphics.drawable.Drawable; | |
import android.graphics.drawable.NinePatchDrawable; | |
import android.util.AttributeSet; | |
import android.widget.RelativeLayout; | |
public class FRelativeLayout extends RelativeLayout { |
import android.os.Build; | |
import android.os.Process; | |
import java.io.ByteArrayOutputStream; | |
import java.io.DataInputStream; | |
import java.io.DataOutputStream; | |
import java.io.File; | |
import java.io.FileInputStream; | |
import java.io.FileOutputStream; | |
import java.io.IOException; |