Skip to content
This repository has been archived by the owner on Sep 28, 2023. It is now read-only.

Commit

Permalink
Merge branch 'release/1.1.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
TakWolf committed Apr 17, 2016
2 parents f29fc0a + e27b5ed commit 4656446
Show file tree
Hide file tree
Showing 125 changed files with 2,016 additions and 1,867 deletions.
50 changes: 38 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
# CNode Material Design [![API](https://img.shields.io/badge/API-9%2B-brightgreen.svg?style=flat)](https://android-arsenal.com/api?level=9) #
![Banner](/art/banner-1024-500.png)

![Logo](/art/ic_launcher.png)
# CNode Material Design #

> [CNode社区](https://cnodejs.org) 第三方Android客户端,原生App,Material Design风格,支持夜间模式
[![Platform](https://img.shields.io/badge/platform-Android-green.svg?style=flat)](http://developer.android.com/index.html)
[![API](https://img.shields.io/badge/API-9%2B-brightgreen.svg?style=flat)](https://android-arsenal.com/api?level=9)
[![License](https://img.shields.io/badge/license-Apache--2.0-blue.svg?style=flat)](http://www.apache.org/licenses/LICENSE-2.0)

> [https://cnodejs.org/topic/55c2f7f15965fe2c74f4791d](https://cnodejs.org/topic/55c2f7f15965fe2c74f4791d)
![Logo](/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png)

[CNode社区](https://cnodejs.org) 第三方Android客户端,原生App,Material Design风格,支持夜间模式

[https://cnodejs.org/topic/55c2f7f15965fe2c74f4791d](https://cnodejs.org/topic/55c2f7f15965fe2c74f4791d)

## Download ##

Expand Down Expand Up @@ -40,24 +46,26 @@

- [Joda-Time](http://www.joda.org/joda-time)

- [Retrofit](http://square.github.io/retrofit)
- [Joda-Time-Android](https://github.com/dlew/joda-time-android)

- [OkHttp](http://square.github.io/okhttp)

- [Picasso](http://square.github.io/picasso)
- [Retrofit](http://square.github.io/retrofit)

- [Glide](https://github.com/bumptech/glide)

- [CircleImageView](https://github.com/hdodenhof/CircleImageView)

- [MaterialEditText](https://github.com/rengwuxian/MaterialEditText)

- [Material Dialogs](https://github.com/afollestad/material-dialogs)

- [materialish-progress](https://github.com/pnikosis/materialish-progress)

- [FloatingActionButton](https://github.com/makovkastar/FloatingActionButton)

- [QRCodeReaderView](https://github.com/dlazaro66/QRCodeReaderView)

- [PhotoView](https://github.com/chrisbanes/PhotoView)

- [MarkdownPapers](http://markdown.tautua.org)

- [Google I/O Android App - ScrimInsetsViews](https://github.com/google/iosched/blob/master/android/src/main/java/com/google/samples/apps/iosched/ui/widget/ScrimInsetsScrollView.java)
Expand Down Expand Up @@ -92,14 +100,32 @@
> [https://cnodejs.org/topic/559bd1b91e5c761761468884](https://cnodejs.org/topic/559bd1b91e5c761761468884)
> PS:基于React Native实现,目前只有IOS版本,作者有计划适配Android。比较不错的技术实践,作者比较活跃。
> PS:基于React Native实现,包含iOS和Android两个平台
### [Vue-cnodejs](https://github.com/shinygang/Vue-cnodejs) ![image](/art/ic_good_project.png) ###

> 基于vue.js重写Cnodejs.org社区的webapp,[线上访问地址](http://shinygang.github.io/cnodevue)
> [https://cnodejs.org/topic/565c4473d0bc14ae279399fe](https://cnodejs.org/topic/565c4473d0bc14ae279399fe)
### [swift-cnode](https://github.com/nswbmw/swift-cnode) ###

> [CNode社区](https://cnodejs.org/) 的又一 swift 客户端,未完成...不定期更新,欢迎 fork 与 PR。
> [https://cnodejs.org/topic/570a7adcbc564eaf3c6a4901](https://cnodejs.org/topic/570a7adcbc564eaf3c6a4901)
### [cnode-angular-material](https://github.com/XGHeaven/cnode-angular-material) ###

> CNode.JS 社区的 Angular-Material 的实现,暂时处于开发状态中 [http://cnode.xgheaven.cn](http://cnode.xgheaven.cn)
> [https://cnodejs.org/topic/566bb3a35af0e6ab3bf1a280](https://cnodejs.org/topic/566bb3a35af0e6ab3bf1a280)
### [Ioniclub](https://github.com/XueRainey/Ioniclub) ###

> Ioniclub is hybird mobile app of [https://cnodejs.org](https://cnodejs.org), web demo [http://rainey.coding.io/ioniclub/](http://rainey.coding.io/ioniclub/)
> [https://cnodejs.org/topic/57111863434cfcfa52684a8e](https://cnodejs.org/topic/57111863434cfcfa52684a8e)
### [CNode-android](https://github.com/iwhys/CNode-android) ###

> 这是为CNodejs社区(https://cnodejs.org) 开发的原生Android版客户端。适用于Android4.0及以上。
Expand Down Expand Up @@ -130,13 +156,13 @@
> PS:CNode社区早期的客户端实践项目,基于Ionic 和 PhoneGap。作者已经很长时间没有更新了。
### [cnodejs-reader](https://github.com/cnodejs/cnodejs-reader) ###
### [cnodejs-reader](https://github.com/cnodejs/cnodejs-reader) ![image](/art/ic_good_project.png) ###

> CNode.js client in React. React 版本的 CNode 网页版。
> CNode.js client in React. Demo: [http://r.nodejs-china.org](http://r.nodejs-china.org)
> [https://cnodejs.org/topic/545b97cc3e1f39344c5b3c1a](https://cnodejs.org/topic/545b97cc3e1f39344c5b3c1a)
> PS:CNode社区早期的客户端实践项目。演示地址在 [http://r.nodejs-china.org](http://r.nodejs-china.org)
> PS:开发基于cirru,一种定制过语法的JavaScript,详情地址在 [http://script.cirru.org](http://script.cirru.org)
### [CNode4WP](https://github.com/heimeil/CNode4WP) ###

Expand Down
25 changes: 12 additions & 13 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@ properties.load(project.rootProject.file('local.properties').newDataInputStream(
android {

compileSdkVersion 23
buildToolsVersion "23.0.2"
buildToolsVersion "23.0.3"

defaultConfig {
applicationId "org.cnodejs.android.md"
minSdkVersion 9
targetSdkVersion 22
versionCode Integer.parseInt(time)
versionName "1.0.14"
versionName "1.1.0"

manifestPlaceholders = [
UMENG_CHANNEL: "CNodeJS",
Expand All @@ -44,25 +44,24 @@ android {

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:design:23.2.0'
compile 'com.android.support:design:23.3.0'

compile 'com.jakewharton:butterknife:7.0.1'
compile 'com.google.code.gson:gson:2.6.1'
compile 'joda-time:joda-time:2.9.2'
compile 'com.squareup.retrofit:retrofit:1.9.0'
compile 'com.squareup.okhttp:okhttp:2.6.0'
compile 'com.squareup.picasso:picasso:2.5.2'
compile 'com.google.code.gson:gson:2.6.2'
compile 'net.danlew:android.joda:2.9.3'
compile 'com.squareup.okhttp3:okhttp:3.2.0'
compile 'com.squareup.okhttp3:logging-interceptor:3.2.0'
compile 'com.squareup.retrofit2:retrofit:2.0.2'
compile 'com.squareup.retrofit2:converter-gson:2.0.2'
compile 'com.github.bumptech.glide:glide:3.7.0'

compile 'de.hdodenhof:circleimageview:2.0.0'
compile 'com.rengwuxian.materialedittext:library:2.1.4'
compile ('com.github.afollestad.material-dialogs:core:0.8.5.5@aar') { transitive = true }
compile 'com.pnikosis:materialish-progress:1.7'
compile 'com.melnykov:floatingactionbutton:1.3.0'

compile 'com.dlazaro66.qrcodereaderview:qrcodereaderview:1.0.0'

compile 'com.github.chrisbanes:PhotoView:1.2.6'
compile 'org.tautua.markdownpapers:markdownpapers-core:1.4.2'

compile project(':umeng-update-sdk')
compile 'com.umeng.analytics:analytics:5.6.4'
compile 'com.umeng.analytics:analytics:5.6.7'
}
45 changes: 20 additions & 25 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
android:theme="@style/AppThemeLight">

<activity
android:name="org.cnodejs.android.md.ui.activity.LaunchActivity"
android:name="org.cnodejs.android.md.display.activity.LaunchActivity"
android:label="@string/app_name"
android:theme="@style/AppThemeLaunch"
android:screenOrientation="portrait"
Expand All @@ -29,82 +29,88 @@
</activity>

<activity
android:name="org.cnodejs.android.md.ui.activity.MainActivity"
android:name="org.cnodejs.android.md.display.activity.MainActivity"
android:label="@string/app_name"
android:theme="@style/AppThemeLight.FitsStatusBar"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

<activity
android:name="org.cnodejs.android.md.ui.activity.LoginActivity"
android:name="org.cnodejs.android.md.display.activity.LoginActivity"
android:label="@string/login"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

<activity
android:name="org.cnodejs.android.md.ui.activity.QRCodeActivity"
android:name="org.cnodejs.android.md.display.activity.QRCodeActivity"
android:label="@string/open_qrcode"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

<activity
android:name="org.cnodejs.android.md.ui.activity.TopicActivity"
android:name="org.cnodejs.android.md.display.activity.TopicActivity"
android:label="@string/topic"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

<activity
android:name="org.cnodejs.android.md.ui.activity.NewTopicActivity"
android:name="org.cnodejs.android.md.display.activity.CreateTopicActivity"
android:label="@string/new_topic"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize"
android:windowSoftInputMode="stateHidden|adjustResize" />

<activity
android:name="org.cnodejs.android.md.ui.activity.MarkdownPreviewActivity"
android:name="org.cnodejs.android.md.display.activity.MarkdownPreviewActivity"
android:label="@string/markdown_preview"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

<activity
android:name="org.cnodejs.android.md.ui.activity.UserDetailActivity"
android:name="org.cnodejs.android.md.display.activity.ImagePreviewActivity"
android:label="@string/image_preview"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

<activity
android:name="org.cnodejs.android.md.display.activity.UserDetailActivity"
android:label="@string/user_detail"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

<activity
android:name="org.cnodejs.android.md.ui.activity.NotificationActivity"
android:name="org.cnodejs.android.md.display.activity.NotificationActivity"
android:label="@string/notification"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

<activity
android:name="org.cnodejs.android.md.ui.activity.SettingActivity"
android:name="org.cnodejs.android.md.display.activity.SettingActivity"
android:label="@string/setting"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

<activity
android:name="org.cnodejs.android.md.ui.activity.ModifyTopicSignActivity"
android:name="org.cnodejs.android.md.display.activity.ModifyTopicSignActivity"
android:label="@string/modify_topic_sign"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

<activity
android:name="org.cnodejs.android.md.ui.activity.AboutActivity"
android:name="org.cnodejs.android.md.display.activity.AboutActivity"
android:label="@string/about"
android:theme="@style/AppThemeLight.FitsStatusBar"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

<activity
android:name="org.cnodejs.android.md.ui.activity.LicenseActivity"
android:name="org.cnodejs.android.md.display.activity.LicenseActivity"
android:label="@string/open_source_license"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

<activity
android:name="org.cnodejs.android.md.ui.activity.CrashLogActivity"
android:name="org.cnodejs.android.md.display.activity.CrashLogActivity"
android:label="@string/app_crash"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />
Expand All @@ -118,17 +124,6 @@
android:name="UMENG_CHANNEL"
android:value="${UMENG_CHANNEL}" />

<!-- 友盟自动更新 -->
<service
android:name="com.umeng.update.net.DownloadingService"
android:process=":DownloadingService" />

<activity
android:name="com.umeng.update.UpdateDialogActivity"
android:theme="@style/AppDialog"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden|screenSize" />

</application>

</manifest>
14 changes: 4 additions & 10 deletions app/src/main/java/org/cnodejs/android/md/app/AppController.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,10 @@

import android.app.Application;
import android.content.Context;
import android.text.TextUtils;

import com.umeng.analytics.MobclickAgent;
import net.danlew.android.joda.JodaTimeAndroid;

import org.cnodejs.android.md.BuildConfig;
import org.cnodejs.android.md.storage.LoginShared;

public class AppController extends Application {

Expand All @@ -22,17 +20,13 @@ public void onCreate() {
super.onCreate();
context = this;

// 初始化JodaTimeAndroid
JodaTimeAndroid.init(this);

// 配置全局异常捕获
if (!BuildConfig.DEBUG) {
Thread.setDefaultUncaughtExceptionHandler(new AppExceptionHandler(this));
}

// TODO 友盟账号统计
if (!TextUtils.isEmpty(LoginShared.getAccessToken(this))) {
MobclickAgent.onProfileSignIn(LoginShared.getLoginName(this));
} else {
MobclickAgent.onProfileSignOff();
}
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import android.content.Intent;
import android.os.Bundle;

import org.cnodejs.android.md.ui.activity.CrashLogActivity;
import org.cnodejs.android.md.display.activity.CrashLogActivity;

public class AppExceptionHandler implements Thread.UncaughtExceptionHandler {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,20 +1,17 @@
package org.cnodejs.android.md.ui.activity;
package org.cnodejs.android.md.display.activity;

import android.content.Intent;
import android.os.Build;
import android.os.Bundle;
import android.support.v7.widget.Toolbar;
import android.widget.TextView;

import com.afollestad.materialdialogs.MaterialDialog;

import org.cnodejs.android.md.BuildConfig;
import org.cnodejs.android.md.R;
import org.cnodejs.android.md.ui.base.StatusBarActivity;
import org.cnodejs.android.md.ui.listener.NavigationFinishClickListener;
import org.cnodejs.android.md.ui.widget.ThemeUtils;
import org.cnodejs.android.md.display.base.StatusBarActivity;
import org.cnodejs.android.md.display.listener.NavigationFinishClickListener;
import org.cnodejs.android.md.display.widget.ThemeUtils;
import org.cnodejs.android.md.util.ShipUtils;
import org.cnodejs.android.md.util.UpdateUtils;

import butterknife.Bind;
import butterknife.ButterKnife;
Expand Down Expand Up @@ -44,7 +41,7 @@ protected void onCreate(Bundle savedInstanceState) {

@OnClick(R.id.about_btn_version)
protected void onBtnVersionClick() {
UpdateUtils.forceUpdate(this);
// nothing to do
}

@OnClick(R.id.about_btn_open_source_url)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package org.cnodejs.android.md.ui.activity;
package org.cnodejs.android.md.display.activity;

import android.content.Intent;
import android.os.Build;
Expand All @@ -8,9 +8,9 @@
import android.widget.TextView;

import org.cnodejs.android.md.R;
import org.cnodejs.android.md.ui.base.StatusBarActivity;
import org.cnodejs.android.md.ui.listener.NavigationFinishClickListener;
import org.cnodejs.android.md.ui.widget.ThemeUtils;
import org.cnodejs.android.md.display.base.StatusBarActivity;
import org.cnodejs.android.md.display.listener.NavigationFinishClickListener;
import org.cnodejs.android.md.display.widget.ThemeUtils;
import org.cnodejs.android.md.util.ShipUtils;
import org.joda.time.DateTime;

Expand Down
Loading

0 comments on commit 4656446

Please sign in to comment.