diff --git a/.classpath b/.classpath index a4763d1..1a9a798 100644 --- a/.classpath +++ b/.classpath @@ -1,8 +1,14 @@ + + + + + + - - + + diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md new file mode 100644 index 0000000..2eefb87 --- /dev/null +++ b/.github/ISSUE_TEMPLATE.md @@ -0,0 +1,13 @@ +## The problem + +Describe the issue you are experiencing, or features you want. + +## Environment + +* Emmagee version +* Device Information: **Brand**, **Model**, **System**. + +## Link to Emmagee logs + +Create a [GIST](https://gist.github.com) which is a paste of your _full_ Emmagee logs, and link them here. +Do _NOT_ paste your full Emmagee logs here, as it will make this issue very long and hard to read! diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e0cba59 --- /dev/null +++ b/.gitignore @@ -0,0 +1,19 @@ +# built application files +*.apk +*.ap_ + +# files for the dex VM +*.dex + +# Java class files +*.class + +# generated files +bin/ +gen/ + +# Local configuration file (sdk path, etc) +local.properties + +lint.xml +.DS_Store \ No newline at end of file diff --git a/AUTHORS b/AUTHORS index 5ffd5f2..a32824e 100644 --- a/AUTHORS +++ b/AUTHORS @@ -1,2 +1,3 @@ * KevinKong * andrewleo +* bingoHuang \ No newline at end of file diff --git a/AndroidManifest.xml b/AndroidManifest.xml index 82d995a..1368e4a 100644 --- a/AndroidManifest.xml +++ b/AndroidManifest.xml @@ -1,42 +1,56 @@ + android:versionCode="34" + android:versionName="2.5.1" > - - + + + android:label="@string/app_name" + android:theme="@android:style/Theme.NoTitleBar" > + android:configChanges="orientation|keyboardHidden" + android:launchMode="singleInstance" + android:screenOrientation="portrait" > - - + - - - - + android:launchMode="singleInstance" + android:screenOrientation="portrait" + android:theme="@style/customTheme" /> + + + + - - + + - - - - - - + + + + + + + + + + \ No newline at end of file diff --git a/README.md b/README.md index fc91244..2eddd66 100644 --- a/README.md +++ b/README.md @@ -1,57 +1,78 @@ -##Emmagee - a practical, handy performance test tool for specified Android App - -Emmagee is a practical, handy performance test tool for specified Android App, which can monitor CPU, memory and -network traffic. Additionally, it also provides several cool features such as customizing interval of collecting data, -rendering real-time process status in a floating window, and much more. - - * Homepage: - * Wiki: - * Issues: - * Tags: Android, Java - -## Features - -* Process-specific monitoring -* Real-time data displaying -* User-defined collecting interval - -## Why should I use Emmagee? - -Unlike other performance test tools that only do system-level monitoring, Emmagee provides the ability to monitor any single App. Other advantages that -you should not miss: -* Open source -* Easy to use -* Floating window rendering real-time process status -* CSV format report that can be converted into any other format you want -* Fully support Android 2.2 and above - -## How to use Emmagee? - -1. Start Emmagee App -2. Configure interval -3. Select a target process -4. Click Start button - -And Enjoy! - -If you want to stop the test, just go back to Emmagee and click Stop button. - -## Contributors -* NetEase, Inc. - -## License -(The Apache License) - -Copyright (c) 2012-2013 NetEase, Inc. and other contributors - - 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 - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. +## Emmagee - a practical, handy performance test tool for specified Android App + +Emmagee is a practical, handy performance test tool for specified Android App, which can monitor CPU, memory, +network traffic, battery current and status([Some devices are not supported](https://github.com/NetEase/Emmagee/wiki/Some-devices-are-not-supported)), new features such as top activity and heap size if rooted([Root Toast may continously show](https://github.com/NetEase/Emmagee/wiki/FAQ)), are also supported in the [latest version](https://github.com/NetEase/Emmagee/releases). Additionally, it also provides several cool features such as customizing interval of collecting data, +rendering real-time process status in a floating window, and much more. + + * Homepage: https://github.com/NetEase/Emmagee + * Wiki: https://github.com/NetEase/Emmagee/wiki + * Issues: https://github.com/NetEase/Emmagee/issues + * FAQ: https://github.com/NetEase/Emmagee/wiki/FAQ + * Tags: Android, Java + +   + +## Why should I use Emmagee? + +Unlike most other performance test tools that only do system-level monitoring, Emmagee provides the ability to monitor any single App. Other advantages that +you should not miss: +* Open source +* Easy to use +* Process-specific monitoring, including CPU, memory, network traffic, battery current, launching time and status +* Floating window that renders real-time process status +* CSV format report that can be converted into any other format you want +* User-defined collecting interval +* Fully support Android 2.2 and above + +## How to use Emmagee? + +First of all ,you should have Emmagee.apk,download [here](https://github.com/NetEase/Emmagee/releases) or +build the apk file youself [here](https://github.com/NetEase/Emmagee/wiki/How-to-build-emmage.apk%3F),then : + +1. Start Emmagee App +2. Configure interval +3. Select a target process +4. Click Start button + +And Enjoy! + +If you want to stop the test, just go back to Emmagee and click Stop button. + +## Android 5.0 and above + +* `Android 5.0 and above`: getRunningTasks() and getRunningAppProcesses() are deprecated and only return your application process, so it is unable to get TopActivity from Android 5.0. +* `Android 7.0`: Google has restricted access to /proc, and also can not get pid of target application from TOP command in Android 7.0, I am so sorry to tell that 7.0 can not be supported. + +## Coming Soon +* We want you to decide! + +## How to Contribute? + +You are welcome to contribute to Emmagee, meanwhile you'd better follow the rules below + +* It's *NOT* recommended to submit a pull request directly to Emmagee's `master` branch. `develop` branch is more appropriate +* Follow common Java coding conventions +* Put all Java class files under *com.netease* package +* Add the following [license](#license) in each Java class file + +## Contributors +* NetEase, Inc. +* [yrom](https://github.com/yrom) +* [LukeOwncloud](https://github.com/LukeOwncloud) + +## License +(The Apache License) + +Copyright (c) 2012-2015 NetEase, Inc. and other contributors + + 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 + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/VERSION b/VERSION index 6c6aa7c..6b4950e 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.1.0 \ No newline at end of file +2.4 diff --git a/apk/Emmagee.apk b/apk/Emmagee.apk deleted file mode 100644 index 632dfc1..0000000 Binary files a/apk/Emmagee.apk and /dev/null differ diff --git a/build.xml b/build.xml deleted file mode 100644 index 620232b..0000000 --- a/build.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/changelog.md b/changelog.md new file mode 100644 index 0000000..a156c91 --- /dev/null +++ b/changelog.md @@ -0,0 +1,44 @@ +Emmagee Changelog + +###2.0 (2014-9-22) +New Features: +* Optimization of UI +* I18N support(Chinese Simplified and English) +* Collect usage of each CPU cores + +Issues Fixed: +* #16 'Save' button is covered when soft keyboard pops up +* #20 Strings hard-coded for language +* #21 CSV report enhancement +* #24 Floating window disappears on some specific devices +* #25 Report unavailable path of CSV when test is over +* #26 Dulplicated toast when test is over + +###1.3.0 (2014-1-6) +New Features: +* Integrate monitoring of app starting time + +Issues fixed +* #12 Add "stop test" button on floating window +* #13 Optimize interface and user experience + +###1.2.1 (2013-11-25) +Issues fixed: +* #10 The CSV report displays abnormally when free memory is above 1000. + +Improvements to : +* #9 List the application with alphabet order. + +###1.2.0 (2013-9-17) +* Support quad-core CPU +* Integrate monitoring of battery current and status + +###1.1.0 (2013-4-8) +* Configure specified recipients to receive test reports +* Automaticly save the result when monitoring app stops + +###1.0.0 (2013-1-18) +* Process-specific monitoring +* Floating window that renders real-time process status +* CSV format report that can be converted into any other format you want +* User-defined collecting interval diff --git a/emmagee.xml b/emmagee.xml new file mode 100644 index 0000000..e617f3f --- /dev/null +++ b/emmagee.xml @@ -0,0 +1,83 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/gen/com/netease/qa/emmagee/R.java b/gen/com/netease/qa/emmagee/R.java deleted file mode 100644 index c006e99..0000000 --- a/gen/com/netease/qa/emmagee/R.java +++ /dev/null @@ -1,72 +0,0 @@ -/* AUTO-GENERATED FILE. DO NOT MODIFY. - * - * This class was automatically generated by the - * aapt tool from the resource data it found. It - * should not be modified by hand. - */ - -package com.netease.qa.emmagee; - -public final class R { - public static final class attr { - } - public static final class drawable { - public static final int button_bg=0x7f020000; - public static final int close=0x7f020001; - public static final int ic_launcher=0x7f020002; - public static final int icon=0x7f020003; - public static final int meminfo=0x7f020004; - } - public static final class id { - public static final int Lin=0x7f050004; - public static final int b=0x7f050001; - public static final int cpu1=0x7f050013; - public static final int cpu2=0x7f050014; - public static final int cpu_info=0x7f050000; - public static final int floating=0x7f050011; - public static final int floating_Window=0x7f050010; - public static final int image=0x7f05000a; - public static final int img1=0x7f050002; - public static final int img2=0x7f050003; - public static final int memoryinfo=0x7f05000e; - public static final int memtotal=0x7f050006; - public static final int memunused=0x7f050005; - public static final int processList=0x7f05000c; - public static final int rb=0x7f050009; - public static final int save=0x7f050012; - public static final int test=0x7f05000d; - public static final int text=0x7f05000b; - public static final int time=0x7f05000f; - public static final int traffic=0x7f050007; - public static final int wifi=0x7f050008; - } - public static final class layout { - public static final int cpu=0x7f030000; - public static final int floating=0x7f030001; - public static final int list_item=0x7f030002; - public static final int mainpage=0x7f030003; - public static final int memory=0x7f030004; - public static final int settings=0x7f030005; - public static final int systemstat=0x7f030006; - } - public static final class string { - public static final int app_name=0x7f040001; - public static final int app_name1=0x7f040002; - public static final int app_name2=0x7f040003; - public static final int app_name3=0x7f040004; - public static final int app_name4=0x7f040005; - public static final int bg=0x7f040009; - public static final int closewifi=0x7f040011; - public static final int collect=0x7f04000c; - public static final int cpu=0x7f040008; - public static final int hello=0x7f040000; - public static final int memoryinfo=0x7f04000b; - public static final int ok=0x7f04000f; - public static final int openwifi=0x7f040010; - public static final int seconds=0x7f04000d; - public static final int start=0x7f040007; - public static final int system=0x7f040006; - public static final int testmemory=0x7f04000a; - public static final int window=0x7f04000e; - } -} diff --git a/libs/activation.jar b/libs/activation.jar new file mode 100644 index 0000000..614a03c Binary files /dev/null and b/libs/activation.jar differ diff --git a/libs/additionnal.jar b/libs/additionnal.jar new file mode 100644 index 0000000..aeb9611 Binary files /dev/null and b/libs/additionnal.jar differ diff --git a/libs/android-support-v4.jar b/libs/android-support-v4.jar new file mode 100644 index 0000000..428bdbc Binary files /dev/null and b/libs/android-support-v4.jar differ diff --git a/libs/commons-io-2.5.jar b/libs/commons-io-2.5.jar new file mode 100644 index 0000000..1234918 Binary files /dev/null and b/libs/commons-io-2.5.jar differ diff --git a/libs/mail.jar b/libs/mail.jar new file mode 100644 index 0000000..2157537 Binary files /dev/null and b/libs/mail.jar differ diff --git a/project.properties b/project.properties index f049142..a5578ba 100644 --- a/project.properties +++ b/project.properties @@ -8,4 +8,4 @@ # project structure. # Project target. -target=android-10 +target=android-19 diff --git a/res/drawable-hdpi/actionbar_bg.9.png b/res/drawable-hdpi/actionbar_bg.9.png new file mode 100644 index 0000000..ea41b6e Binary files /dev/null and b/res/drawable-hdpi/actionbar_bg.9.png differ diff --git a/res/drawable-hdpi/bottom_bg.png b/res/drawable-hdpi/bottom_bg.png new file mode 100644 index 0000000..fa426fe Binary files /dev/null and b/res/drawable-hdpi/bottom_bg.png differ diff --git a/res/drawable-hdpi/btn_back.png b/res/drawable-hdpi/btn_back.png new file mode 100644 index 0000000..d154f5d Binary files /dev/null and b/res/drawable-hdpi/btn_back.png differ diff --git a/res/drawable-hdpi/btn_save.png b/res/drawable-hdpi/btn_save.png new file mode 100644 index 0000000..43fc20e Binary files /dev/null and b/res/drawable-hdpi/btn_save.png differ diff --git a/res/drawable-hdpi/btn_test.png b/res/drawable-hdpi/btn_test.png new file mode 100644 index 0000000..e497a64 Binary files /dev/null and b/res/drawable-hdpi/btn_test.png differ diff --git a/res/drawable-hdpi/btn_test_press.png b/res/drawable-hdpi/btn_test_press.png new file mode 100644 index 0000000..f87e0db Binary files /dev/null and b/res/drawable-hdpi/btn_test_press.png differ diff --git a/res/drawable-hdpi/checked_icon.png b/res/drawable-hdpi/checked_icon.png new file mode 100644 index 0000000..66727de Binary files /dev/null and b/res/drawable-hdpi/checked_icon.png differ diff --git a/res/drawable-hdpi/left_arrow.png b/res/drawable-hdpi/left_arrow.png new file mode 100644 index 0000000..d102ef9 Binary files /dev/null and b/res/drawable-hdpi/left_arrow.png differ diff --git a/res/drawable-hdpi/refresh.png b/res/drawable-hdpi/refresh.png new file mode 100644 index 0000000..2eab627 Binary files /dev/null and b/res/drawable-hdpi/refresh.png differ diff --git a/res/drawable-hdpi/right_arrow.png b/res/drawable-hdpi/right_arrow.png new file mode 100644 index 0000000..ca9c12d Binary files /dev/null and b/res/drawable-hdpi/right_arrow.png differ diff --git a/res/drawable-hdpi/seekbar_thumb_normal.png b/res/drawable-hdpi/seekbar_thumb_normal.png new file mode 100644 index 0000000..91b9362 Binary files /dev/null and b/res/drawable-hdpi/seekbar_thumb_normal.png differ diff --git a/res/drawable-hdpi/seekbar_thumb_pressed.png b/res/drawable-hdpi/seekbar_thumb_pressed.png new file mode 100644 index 0000000..b897d22 Binary files /dev/null and b/res/drawable-hdpi/seekbar_thumb_pressed.png differ diff --git a/res/drawable-hdpi/settings.png b/res/drawable-hdpi/settings.png new file mode 100644 index 0000000..68d9f5f Binary files /dev/null and b/res/drawable-hdpi/settings.png differ diff --git a/res/drawable-hdpi/settings_pressed.png b/res/drawable-hdpi/settings_pressed.png new file mode 100644 index 0000000..b8e5bff Binary files /dev/null and b/res/drawable-hdpi/settings_pressed.png differ diff --git a/res/drawable-hdpi/unchecked_icon.png b/res/drawable-hdpi/unchecked_icon.png new file mode 100644 index 0000000..ef99cc5 Binary files /dev/null and b/res/drawable-hdpi/unchecked_icon.png differ diff --git a/res/drawable/custom_checkbox.xml b/res/drawable/custom_checkbox.xml new file mode 100644 index 0000000..faaac8f --- /dev/null +++ b/res/drawable/custom_checkbox.xml @@ -0,0 +1,7 @@ + + + + + + + \ No newline at end of file diff --git a/res/drawable/custom_seekbar.xml b/res/drawable/custom_seekbar.xml new file mode 100644 index 0000000..00981cc --- /dev/null +++ b/res/drawable/custom_seekbar.xml @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/res/drawable/float_button.xml b/res/drawable/float_button.xml new file mode 100644 index 0000000..bf1fc3c --- /dev/null +++ b/res/drawable/float_button.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/res/drawable/seekbar_thumb.xml b/res/drawable/seekbar_thumb.xml new file mode 100644 index 0000000..a0028b4 --- /dev/null +++ b/res/drawable/seekbar_thumb.xml @@ -0,0 +1,8 @@ + + + + + + + \ No newline at end of file diff --git a/res/drawable/settings_button.xml b/res/drawable/settings_button.xml new file mode 100644 index 0000000..872cc86 --- /dev/null +++ b/res/drawable/settings_button.xml @@ -0,0 +1,5 @@ + + + + diff --git a/res/drawable/table_border.xml b/res/drawable/table_border.xml new file mode 100644 index 0000000..bb001ed --- /dev/null +++ b/res/drawable/table_border.xml @@ -0,0 +1,15 @@ + + + + + + + + \ No newline at end of file diff --git a/res/drawable/test_button.xml b/res/drawable/test_button.xml new file mode 100644 index 0000000..36582e6 --- /dev/null +++ b/res/drawable/test_button.xml @@ -0,0 +1,8 @@ + + + + + + + diff --git a/res/layout/about.xml b/res/layout/about.xml new file mode 100644 index 0000000..0d6c386 --- /dev/null +++ b/res/layout/about.xml @@ -0,0 +1,125 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/res/layout/cpu.xml b/res/layout/cpu.xml deleted file mode 100644 index e3f23ec..0000000 --- a/res/layout/cpu.xml +++ /dev/null @@ -1,17 +0,0 @@ - - - - -