Created
September 22, 2015 02:24
-
-
Save larboy1991/0603ba46c7c9804ea826 to your computer and use it in GitHub Desktop.
阿斯顿
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
<?xml version="1.0" encoding="UTF-8"?> | |
<classpath> | |
<classpathentry kind="src" path="src"/> | |
<classpathentry kind="src" path="gen"/> | |
<classpathentry kind="con" path="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"/> | |
<classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.LIBRARIES"/> | |
<classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.DEPENDENCIES"/> | |
<classpathentry kind="lib" path="libs/android-async-http-1.4.6.jar"/> | |
<classpathentry kind="lib" path="libs/avoscloud-sdk-v3.7.2.jar"/> | |
<classpathentry kind="lib" path="libs/fastjson.jar"/> | |
<classpathentry kind="lib" path="libs/httpmime-4.2.4.jar"/> | |
<classpathentry kind="output" path="bin/classes"/> | |
</classpath> |
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
MyHome |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<project version="4"> | |
<component name="CompilerConfiguration"> | |
<resourceExtensions /> | |
<wildcardResourcePatterns> | |
<entry name="!?*.java" /> | |
<entry name="!?*.form" /> | |
<entry name="!?*.class" /> | |
<entry name="!?*.groovy" /> | |
<entry name="!?*.scala" /> | |
<entry name="!?*.flex" /> | |
<entry name="!?*.kt" /> | |
<entry name="!?*.clj" /> | |
<entry name="!?*.aj" /> | |
</wildcardResourcePatterns> | |
<annotationProcessing> | |
<profile default="true" name="Default" enabled="false"> | |
<processorPath useClasspath="true" /> | |
</profile> | |
</annotationProcessing> | |
</component> | |
</project> |
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
<component name="CopyrightManager"> | |
<settings default="" /> | |
</component> |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<project version="4"> | |
<component name="GradleSettings"> | |
<option name="linkedExternalProjectsSettings"> | |
<GradleProjectSettings> | |
<option name="distributionType" value="DEFAULT_WRAPPED" /> | |
<option name="externalProjectPath" value="$PROJECT_DIR$" /> | |
<option name="gradleJvm" value="1.8" /> | |
<option name="modules"> | |
<set> | |
<option value="$PROJECT_DIR$" /> | |
</set> | |
</option> | |
</GradleProjectSettings> | |
</option> | |
</component> | |
</project> |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<project version="4"> | |
<component name="ProjectLevelVcsManager" settingsEditedManually="false"> | |
<OptionsSetting value="true" id="Add" /> | |
<OptionsSetting value="true" id="Remove" /> | |
<OptionsSetting value="true" id="Checkout" /> | |
<OptionsSetting value="true" id="Update" /> | |
<OptionsSetting value="true" id="Status" /> | |
<OptionsSetting value="true" id="Edit" /> | |
<ConfirmationsSetting value="0" id="Add" /> | |
<ConfirmationsSetting value="0" id="Remove" /> | |
</component> | |
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_6" default="true" assert-keyword="true" jdk-15="true"> | |
<output url="file://$PROJECT_DIR$/build/classes" /> | |
</component> | |
<component name="ProjectType"> | |
<option name="id" value="Android" /> | |
</component> | |
<component name="masterDetails"> | |
<states> | |
<state key="ProjectJDKs.UI"> | |
<settings> | |
<last-edited>1.8</last-edited> | |
<splitter-proportions> | |
<option name="proportions"> | |
<list> | |
<option value="0.2" /> | |
</list> | |
</option> | |
</splitter-proportions> | |
</settings> | |
</state> | |
</states> | |
</component> | |
</project> |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<project version="4"> | |
<component name="ProjectModuleManager"> | |
<modules> | |
<module fileurl="file://$PROJECT_DIR$/MyHome.iml" filepath="$PROJECT_DIR$/MyHome.iml" /> | |
</modules> | |
</component> | |
</project> |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<project version="4"> | |
<component name="RunConfigurationProducerService"> | |
<option name="ignoredProducers"> | |
<set> | |
<option value="org.jetbrains.plugins.gradle.execution.test.runner.AllInPackageGradleConfigurationProducer" /> | |
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestClassGradleConfigurationProducer" /> | |
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestMethodGradleConfigurationProducer" /> | |
</set> | |
</option> | |
</component> | |
</project> |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<project version="4"> | |
<component name="VcsDirectoryMappings"> | |
<mapping directory="" vcs="" /> | |
</component> | |
</project> |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<projectDescription> | |
<name>MyHome</name> | |
<comment></comment> | |
<projects> | |
</projects> | |
<buildSpec> | |
<buildCommand> | |
<name>com.android.ide.eclipse.adt.ResourceManagerBuilder</name> | |
<arguments> | |
</arguments> | |
</buildCommand> | |
<buildCommand> | |
<name>com.android.ide.eclipse.adt.PreCompilerBuilder</name> | |
<arguments> | |
</arguments> | |
</buildCommand> | |
<buildCommand> | |
<name>org.eclipse.jdt.core.javabuilder</name> | |
<arguments> | |
</arguments> | |
</buildCommand> | |
<buildCommand> | |
<name>com.android.ide.eclipse.adt.ApkBuilder</name> | |
<arguments> | |
</arguments> | |
</buildCommand> | |
</buildSpec> | |
<natures> | |
<nature>com.android.ide.eclipse.adt.AndroidNature</nature> | |
<nature>org.eclipse.jdt.core.javanature</nature> | |
</natures> | |
</projectDescription> |
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
eclipse.preferences.version=1 | |
encoding/<project>=UTF-8 |
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
eclipse.preferences.version=1 | |
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 | |
org.eclipse.jdt.core.compiler.compliance=1.6 | |
org.eclipse.jdt.core.compiler.source=1.6 |
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
<?xml version="1.0" encoding="utf-8"?> | |
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | |
package="com.mysoft.myhome" | |
android:versionCode="1" | |
android:versionName="1.0" > | |
<uses-sdk | |
android:minSdkVersion="13" | |
android:targetSdkVersion="19" /> | |
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /> | |
<uses-permission android:name="android.permission.INTERNET" /> | |
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> | |
<uses-permission android:name="android.permission.READ_PHONE_STATE" /> | |
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" /> | |
<application | |
android:name="com.mysoft.myhome.MyApplication" | |
android:allowBackup="true" | |
android:icon="@drawable/ic_launcher" | |
android:label="@string/app_name" | |
android:theme="@android:style/Theme.Holo.Light.NoActionBar" > | |
<activity | |
android:name="com.mysoft.myhome.activity.MainActivity" | |
android:label="@string/app_name" > | |
<intent-filter> | |
<action android:name="android.intent.action.MAIN" /> | |
<category android:name="android.intent.category.LAUNCHER" /> | |
</intent-filter> | |
</activity> | |
<activity | |
android:name="com.mysoft.myhome.activity.SubmitInfoActivity" | |
android:windowSoftInputMode="adjustPan|stateHidden" > | |
</activity> | |
<activity android:name="com.mysoft.myhome.activity.SearchAllInfoActivity" > | |
</activity> | |
<activity android:name="com.mysoft.myhome.activity.SearchPerInfoActivity" > | |
</activity> | |
<activity android:name="com.mysoft.myhome.activity.BaseActivity" > | |
</activity> | |
</application> | |
</manifest> |
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
<?xml version="1.0" encoding="utf-8"?> | |
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | |
package="com.mysoft.myhome" | |
android:versionCode="1" | |
android:versionName="1.0" > | |
<uses-sdk | |
android:minSdkVersion="13" | |
android:targetSdkVersion="19" /> | |
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /> | |
<uses-permission android:name="android.permission.INTERNET" /> | |
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> | |
<uses-permission android:name="android.permission.READ_PHONE_STATE" /> | |
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" /> | |
<application | |
android:name="com.mysoft.myhome.MyApplication" | |
android:allowBackup="true" | |
android:icon="@drawable/ic_launcher" | |
android:label="@string/app_name" | |
android:theme="@android:style/Theme.Holo.Light.NoActionBar" > | |
<activity | |
android:name="com.mysoft.myhome.activity.MainActivity" | |
android:label="@string/app_name" > | |
<intent-filter> | |
<action android:name="android.intent.action.MAIN" /> | |
<category android:name="android.intent.category.LAUNCHER" /> | |
</intent-filter> | |
</activity> | |
<activity | |
android:name="com.mysoft.myhome.activity.SubmitInfoActivity" | |
android:windowSoftInputMode="adjustPan|stateHidden" > | |
</activity> | |
<activity android:name="com.mysoft.myhome.activity.SearchAllInfoActivity" > | |
</activity> | |
<activity android:name="com.mysoft.myhome.activity.SearchPerInfoActivity" > | |
</activity> | |
<activity android:name="com.mysoft.myhome.activity.BaseActivity" > | |
</activity> | |
</application> | |
</manifest> |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.app.Activity; | |
import android.os.Bundle; | |
import android.os.Build.VERSION; | |
import android.view.Window; | |
public class BaseActivity extends Activity { | |
public BaseActivity() { | |
} | |
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
if(VERSION.SDK_INT > 18) { | |
Window window = this.getWindow(); | |
window.setFlags(67108864, 67108864); | |
window.setFlags(134217728, 134217728); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import com.mysoft.myhome.activity.LogoActivity; | |
class LogoActivity$1 implements Runnable { | |
LogoActivity$1(LogoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void run() { | |
try { | |
Thread.sleep(1000L); | |
this.this$0.startActivity(this.this$0.it_main); | |
} catch (InterruptedException var5) { | |
this.this$0.startActivity(this.this$0.it_main); | |
} finally { | |
this.this$0.finish(); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.content.Intent; | |
import android.os.Bundle; | |
import com.mysoft.myhome.activity.BaseActivity; | |
import com.mysoft.myhome.activity.MainActivity; | |
public class LogoActivity extends BaseActivity { | |
Intent it_main; | |
public LogoActivity() { | |
} | |
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
this.setContentView(2130903044); | |
this.it_main = new Intent(this, MainActivity.class); | |
this.intentThread(); | |
} | |
public void intentThread() { | |
(new Thread(new Runnable() { | |
public void run() { | |
try { | |
Thread.sleep(1000L); | |
LogoActivity.this.startActivity(LogoActivity.this.it_main); | |
} catch (InterruptedException var5) { | |
LogoActivity.this.startActivity(LogoActivity.this.it_main); | |
} finally { | |
LogoActivity.this.finish(); | |
} | |
} | |
})).start(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.widget.RadioButton; | |
import android.widget.RadioGroup; | |
import android.widget.RadioGroup.OnCheckedChangeListener; | |
import com.mysoft.myhome.activity.MainActivity; | |
import com.mysoft.myhome.fragment.Fragment_Home; | |
import com.mysoft.myhome.fragment.Fragment_Setting; | |
import com.mysoft.myhome.fragment.Fragment_User; | |
class MainActivity$1 implements OnCheckedChangeListener { | |
MainActivity$1(MainActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onCheckedChanged(RadioGroup group, int checkedId) { | |
int length = group.getChildCount(); | |
for(int i = 0; i < length; ++i) { | |
RadioButton rgo = (RadioButton)group.getChildAt(i); | |
if(rgo.getId() == checkedId) { | |
rgo.setBackgroundColor(this.this$0.getResources().getColor(2131099649)); | |
} else { | |
rgo.setBackgroundColor(this.this$0.getResources().getColor(2131099648)); | |
} | |
} | |
switch(checkedId) { | |
case 2131034115: | |
if(MainActivity.access$0(this.this$0) == null) { | |
MainActivity.access$1(this.this$0, new Fragment_Home()); | |
} | |
MainActivity.access$3(this.this$0, MainActivity.access$2(this.this$0), MainActivity.access$0(this.this$0)); | |
break; | |
case 2131034116: | |
if(MainActivity.access$4(this.this$0) == null) { | |
MainActivity.access$5(this.this$0, new Fragment_User()); | |
} | |
MainActivity.access$3(this.this$0, MainActivity.access$2(this.this$0), MainActivity.access$4(this.this$0)); | |
break; | |
case 2131034117: | |
if(MainActivity.access$6(this.this$0) == null) { | |
MainActivity.access$7(this.this$0, new Fragment_Setting()); | |
} | |
MainActivity.access$3(this.this$0, MainActivity.access$2(this.this$0), MainActivity.access$6(this.this$0)); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import com.mysoft.myhome.activity.MainActivity; | |
import java.util.TimerTask; | |
class MainActivity$2 extends TimerTask { | |
MainActivity$2(MainActivity var1) { | |
this.this$0 = var1; | |
} | |
public void run() { | |
this.this$0.isdown = false; | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.graphics.Bitmap; | |
import android.graphics.BitmapFactory; | |
import com.avos.avoscloud.AVException; | |
import com.avos.avoscloud.GetDataCallback; | |
import com.mysoft.myhome.activity.MainActivity; | |
import com.mysoft.myhome.activity.MainActivity.3; | |
class MainActivity$3$1 extends GetDataCallback { | |
MainActivity$3$1(3 var1, String var2) { | |
this.this$1 = var1; | |
this.val$str = var2; | |
} | |
public void done(byte[] arg0, AVException arg1) { | |
Bitmap bitmap = BitmapFactory.decodeByteArray(arg0, 0, arg0.length); | |
bitmap = Bitmap.createScaledBitmap(bitmap, 200, 200, true); | |
MainActivity.access$8(3.access$0(this.this$1)).put(this.val$str, bitmap, 7200); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.graphics.Bitmap; | |
import android.graphics.BitmapFactory; | |
import com.avos.avoscloud.AVException; | |
import com.avos.avoscloud.AVFile; | |
import com.avos.avoscloud.AVObject; | |
import com.avos.avoscloud.FindCallback; | |
import com.mysoft.myhome.activity.MainActivity; | |
import com.mysoft.myhome.activity.MainActivity$3$1; | |
import java.util.List; | |
import java.util.Set; | |
class MainActivity$3 extends FindCallback<AVObject> { | |
MainActivity$3(MainActivity var1, Set var2) { | |
this.this$0 = var1; | |
this.val$siteno = var2; | |
} | |
public void done(List<AVObject> arg0, AVException arg1) { | |
for(int i = 0; i < arg0.size(); ++i) { | |
AVObject post = (AVObject)arg0.get(i); | |
String str = post.getString("uname"); | |
this.val$siteno.add(str); | |
AVFile avFile = post.getAVFile("img"); | |
if(avFile == null) { | |
Bitmap bitmap = BitmapFactory.decodeResource(this.this$0.getResources(), 2130837547); | |
bitmap = Bitmap.createScaledBitmap(bitmap, 200, 200, true); | |
MainActivity.access$8(this.this$0).put(str, bitmap, 7200); | |
} else { | |
avFile.getDataInBackground(new MainActivity$3$1(this, str)); | |
} | |
} | |
this.this$0.shareDate.setList("302home", this.val$siteno); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.graphics.Bitmap; | |
import android.graphics.BitmapFactory; | |
import android.os.Bundle; | |
import android.os.Build.VERSION; | |
import android.support.v4.app.Fragment; | |
import android.support.v4.app.FragmentActivity; | |
import android.support.v4.app.FragmentManager; | |
import android.support.v4.app.FragmentTransaction; | |
import android.view.KeyEvent; | |
import android.view.Window; | |
import android.widget.RadioButton; | |
import android.widget.RadioGroup; | |
import android.widget.RadioGroup.OnCheckedChangeListener; | |
import com.avos.avoscloud.AVException; | |
import com.avos.avoscloud.AVFile; | |
import com.avos.avoscloud.AVObject; | |
import com.avos.avoscloud.AVQuery; | |
import com.avos.avoscloud.FindCallback; | |
import com.avos.avoscloud.GetDataCallback; | |
import com.mysoft.myhome.fragment.Fragment_Home; | |
import com.mysoft.myhome.fragment.Fragment_Setting; | |
import com.mysoft.myhome.fragment.Fragment_User; | |
import com.mysoft.myhome.utils.ACache; | |
import com.mysoft.myhome.utils.AllUtils; | |
import com.mysoft.myhome.utils.MyPreferences; | |
import java.util.HashSet; | |
import java.util.List; | |
import java.util.Timer; | |
import java.util.TimerTask; | |
public class MainActivity extends FragmentActivity { | |
private RadioGroup mGroup; | |
private Fragment homeFragment; | |
private Fragment userFragment; | |
private Fragment settingFragment; | |
private Fragment mContent; | |
private FragmentManager fm; | |
MyPreferences shareDate; | |
private ACache mCache; | |
boolean isdown = false; | |
public MainActivity() { | |
} | |
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
this.setContentView(2130903040); | |
if(VERSION.SDK_INT > 18) { | |
Window window = this.getWindow(); | |
window.setFlags(67108864, 67108864); | |
window.setFlags(134217728, 134217728); | |
} | |
this.shareDate = new MyPreferences(this); | |
this.mCache = ACache.get(this); | |
this.getNamesImgs(); | |
this.initFragment(); | |
this.initView(); | |
} | |
private void initFragment() { | |
this.fm = this.getSupportFragmentManager(); | |
this.homeFragment = new Fragment_Home(); | |
this.mContent = this.homeFragment; | |
this.fm.beginTransaction().replace(2131034118, this.mContent).commit(); | |
} | |
private void initView() { | |
this.mGroup = (RadioGroup)this.findViewById(2131034114); | |
this.mGroup.setOnCheckedChangeListener(new OnCheckedChangeListener() { | |
public void onCheckedChanged(RadioGroup group, int checkedId) { | |
int length = group.getChildCount(); | |
for(int i = 0; i < length; ++i) { | |
RadioButton rgo = (RadioButton)group.getChildAt(i); | |
if(rgo.getId() == checkedId) { | |
rgo.setBackgroundColor(MainActivity.this.getResources().getColor(2131099649)); | |
} else { | |
rgo.setBackgroundColor(MainActivity.this.getResources().getColor(2131099648)); | |
} | |
} | |
switch(checkedId) { | |
case 2131034115: | |
if(MainActivity.this.homeFragment == null) { | |
MainActivity.this.homeFragment = new Fragment_Home(); | |
} | |
MainActivity.this.changeFragment(MainActivity.this.mContent, MainActivity.this.homeFragment); | |
break; | |
case 2131034116: | |
if(MainActivity.this.userFragment == null) { | |
MainActivity.this.userFragment = new Fragment_User(); | |
} | |
MainActivity.this.changeFragment(MainActivity.this.mContent, MainActivity.this.userFragment); | |
break; | |
case 2131034117: | |
if(MainActivity.this.settingFragment == null) { | |
MainActivity.this.settingFragment = new Fragment_Setting(); | |
} | |
MainActivity.this.changeFragment(MainActivity.this.mContent, MainActivity.this.settingFragment); | |
} | |
} | |
}); | |
} | |
private void changeFragment(Fragment from, Fragment to) { | |
this.mContent = to; | |
FragmentTransaction ft = this.fm.beginTransaction(); | |
if(!to.isAdded()) { | |
ft.hide(from).add(2131034118, to).commit(); | |
} else { | |
ft.hide(from).show(to).commit(); | |
} | |
} | |
public boolean onKeyDown(int keyCode, KeyEvent event) { | |
switch(keyCode) { | |
case 4: | |
this.backExit(); | |
default: | |
return true; | |
} | |
} | |
private void backExit() { | |
Timer timer = new Timer(); | |
if(!this.isdown) { | |
this.isdown = true; | |
AllUtils.showToast(this, "再次点击退出程序"); | |
TimerTask task = new TimerTask() { | |
public void run() { | |
MainActivity.this.isdown = false; | |
} | |
}; | |
timer.schedule(task, 2000L); | |
} else { | |
this.finish(); | |
this.mCache.remove("testBitmap"); | |
System.exit(0); | |
} | |
} | |
public void getNamesImgs() { | |
String home = "302home"; | |
final HashSet siteno = new HashSet(); | |
AVQuery query = new AVQuery("userTable"); | |
query.orderByAscending("uid"); | |
query.findInBackground(new FindCallback() { | |
public void done(List<AVObject> arg0, AVException arg1) { | |
for(int i = 0; i < arg0.size(); ++i) { | |
AVObject post = (AVObject)arg0.get(i); | |
final String str = post.getString("uname"); | |
siteno.add(str); | |
AVFile avFile = post.getAVFile("img"); | |
if(avFile == null) { | |
Bitmap bitmap = BitmapFactory.decodeResource(MainActivity.this.getResources(), 2130837547); | |
bitmap = Bitmap.createScaledBitmap(bitmap, 200, 200, true); | |
MainActivity.this.mCache.put(str, bitmap, 7200); | |
} else { | |
avFile.getDataInBackground(new GetDataCallback() { | |
public void done(byte[] arg0, AVException arg1) { | |
Bitmap bitmap = BitmapFactory.decodeByteArray(arg0, 0, arg0.length); | |
bitmap = Bitmap.createScaledBitmap(bitmap, 200, 200, true); | |
MainActivity.this.mCache.put(str, bitmap, 7200); | |
} | |
}); | |
} | |
} | |
MainActivity.this.shareDate.setList("302home", siteno); | |
} | |
}); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import com.mysoft.myhome.activity.SearchAllInfoActivity; | |
class SearchAllInfoActivity$1 implements OnClickListener { | |
SearchAllInfoActivity$1(SearchAllInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(View v) { | |
this.this$0.finish(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import com.avos.avoscloud.AVException; | |
import com.avos.avoscloud.SaveCallback; | |
import com.mysoft.myhome.activity.SearchAllInfoActivity; | |
import com.mysoft.myhome.utils.AllUtils; | |
class SearchAllInfoActivity$10 extends SaveCallback { | |
SearchAllInfoActivity$10(SearchAllInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void done(AVException arg0) { | |
if(arg0 == null) { | |
AllUtils.showToast(this.this$0, "结算成功"); | |
SearchAllInfoActivity.access$2(this.this$0).setVisibility(0); | |
SearchAllInfoActivity.access$1(this.this$0).dismiss(); | |
SearchAllInfoActivity.access$4(this.this$0); | |
} else { | |
AllUtils.showToast(this.this$0, "结算失败,请重试"); | |
SearchAllInfoActivity.access$2(this.this$0).setVisibility(0); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import com.mysoft.myhome.activity.SearchAllInfoActivity; | |
class SearchAllInfoActivity$2 implements OnClickListener { | |
SearchAllInfoActivity$2(SearchAllInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(View v) { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.graphics.Color; | |
import android.graphics.drawable.ColorDrawable; | |
import com.mysoft.myhome.activity.SearchAllInfoActivity; | |
import com.mysoft.myhome.slidelistview.SwipeMenu; | |
import com.mysoft.myhome.slidelistview.SwipeMenuCreator; | |
import com.mysoft.myhome.slidelistview.SwipeMenuItem; | |
class SearchAllInfoActivity$3 implements SwipeMenuCreator { | |
SearchAllInfoActivity$3(SearchAllInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void create(SwipeMenu menu) { | |
this.this$0.payItem = new SwipeMenuItem(this.this$0); | |
this.this$0.payItem.setBackground(new ColorDrawable(Color.rgb(4, 152, 216))); | |
this.this$0.payItem.setWidth(this.this$0.dp2px(120)); | |
this.this$0.payItem.setTitle("结算"); | |
this.this$0.payItem.setTitleSize(18); | |
this.this$0.payItem.setTitleColor(-1); | |
switch(menu.getViewType()) { | |
case 0: | |
menu.addMenuItem(this.this$0.payItem); | |
case 1: | |
default: | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.widget.AbsListView; | |
import android.widget.AbsListView.OnScrollListener; | |
import com.mysoft.myhome.activity.SearchAllInfoActivity; | |
class SearchAllInfoActivity$4 implements OnScrollListener { | |
private int lastItemIndex; | |
SearchAllInfoActivity$4(SearchAllInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onScrollStateChanged(AbsListView view, int scrollState) { | |
if(scrollState == 0 && this.lastItemIndex == this.this$0.adapter.getCount() - 1) { | |
this.this$0.getOtherInfo(); | |
} | |
} | |
public void onScroll(AbsListView view, int firstVisibleItem, int visibleItemCount, int totalItemCount) { | |
this.lastItemIndex = firstVisibleItem + visibleItemCount - 1 - 1; | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import com.mysoft.myhome.activity.SearchAllInfoActivity; | |
import com.mysoft.myhome.slidelistview.SwipeMenu; | |
import com.mysoft.myhome.slidelistview.SwipeMenuListView.OnMenuItemClickListener; | |
class SearchAllInfoActivity$5 implements OnMenuItemClickListener { | |
SearchAllInfoActivity$5(SearchAllInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public boolean onMenuItemClick(int position, SwipeMenu menu, int index) { | |
SearchAllInfoActivity.access$0(this.this$0, position); | |
return false; | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.util.Log; | |
import com.avos.avoscloud.AVException; | |
import com.avos.avoscloud.AVObject; | |
import com.avos.avoscloud.FindCallback; | |
import com.mysoft.myhome.activity.SearchAllInfoActivity; | |
import com.mysoft.myhome.utils.AllUtils; | |
import java.util.List; | |
class SearchAllInfoActivity$6 extends FindCallback<AVObject> { | |
SearchAllInfoActivity$6(SearchAllInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void done(List<AVObject> avObjects, AVException e) { | |
if(e == null) { | |
Log.d("成功", "查询到" + avObjects.size() + " 条符合条件的数据"); | |
this.this$0.list = avObjects; | |
this.this$0.adapter.setData(this.this$0.list); | |
} else { | |
Log.d("失败", "查询失败"); | |
AllUtils.showToast(this.this$0, "查询错误"); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.util.Log; | |
import com.avos.avoscloud.AVException; | |
import com.avos.avoscloud.AVObject; | |
import com.avos.avoscloud.FindCallback; | |
import com.mysoft.myhome.activity.SearchAllInfoActivity; | |
import com.mysoft.myhome.utils.AllUtils; | |
import java.util.List; | |
class SearchAllInfoActivity$7 extends FindCallback<AVObject> { | |
SearchAllInfoActivity$7(SearchAllInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void done(List<AVObject> avObjects, AVException e) { | |
if(e == null) { | |
if(avObjects.size() != 0) { | |
++this.this$0.index; | |
this.this$0.list.addAll(avObjects); | |
this.this$0.adapter.setData(this.this$0.list); | |
this.this$0.foot_text.setText("加载更多"); | |
this.this$0.foot_bar.setVisibility(8); | |
} else { | |
this.this$0.foot_text.setText("没有更多数据了"); | |
this.this$0.foot_bar.setVisibility(8); | |
} | |
} else { | |
Log.d("失败", "查询失败"); | |
AllUtils.showToast(this.this$0, "查询错误"); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import com.mysoft.myhome.activity.SearchAllInfoActivity; | |
class SearchAllInfoActivity$8 implements OnClickListener { | |
SearchAllInfoActivity$8(SearchAllInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(View v) { | |
SearchAllInfoActivity.access$1(this.this$0).dismiss(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import com.mysoft.myhome.activity.SearchAllInfoActivity; | |
class SearchAllInfoActivity$9 implements OnClickListener { | |
SearchAllInfoActivity$9(SearchAllInfoActivity var1, String var2) { | |
this.this$0 = var1; | |
this.val$objectId = var2; | |
} | |
public void onClick(View v) { | |
SearchAllInfoActivity.access$2(this.this$0).setVisibility(0); | |
SearchAllInfoActivity.access$3(this.this$0, this.val$objectId); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.graphics.Color; | |
import android.graphics.drawable.BitmapDrawable; | |
import android.graphics.drawable.ColorDrawable; | |
import android.os.Bundle; | |
import android.util.Log; | |
import android.util.TypedValue; | |
import android.view.LayoutInflater; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.view.View.OnClickListener; | |
import android.widget.AbsListView; | |
import android.widget.Button; | |
import android.widget.PopupWindow; | |
import android.widget.ProgressBar; | |
import android.widget.TextView; | |
import android.widget.AbsListView.OnScrollListener; | |
import com.avos.avoscloud.AVException; | |
import com.avos.avoscloud.AVObject; | |
import com.avos.avoscloud.AVQuery; | |
import com.avos.avoscloud.FindCallback; | |
import com.avos.avoscloud.SaveCallback; | |
import com.mysoft.myhome.activity.BaseActivity; | |
import com.mysoft.myhome.adapter.MySerchAdapter; | |
import com.mysoft.myhome.slidelistview.SwipeMenu; | |
import com.mysoft.myhome.slidelistview.SwipeMenuCreator; | |
import com.mysoft.myhome.slidelistview.SwipeMenuItem; | |
import com.mysoft.myhome.slidelistview.SwipeMenuListView; | |
import com.mysoft.myhome.slidelistview.SwipeMenuListView.OnMenuItemClickListener; | |
import com.mysoft.myhome.utils.AllUtils; | |
import com.mysoft.myhome.utils.MainUtils; | |
import java.util.List; | |
public class SearchAllInfoActivity extends BaseActivity { | |
private TextView title_text; | |
private Button title_back; | |
private Button search_btn_all; | |
private SwipeMenuListView mListView; | |
MainUtils mUtils; | |
String str_date; | |
MySerchAdapter adapter; | |
List<AVObject> list; | |
SwipeMenuItem payItem; | |
private PopupWindow popupWindow; | |
private View popView; | |
private View parent; | |
private TextView popup_text_date; | |
private TextView popup_text_money; | |
private TextView popup_text_who; | |
private TextView popup_text_yufu; | |
private Button popup_btn_cancel; | |
private Button popup_btn_sure; | |
private ProgressBar popup_bar_wait; | |
View view_list_foot; | |
int firstGet = 25; | |
int nextGet = 10; | |
int index = 0; | |
TextView foot_text; | |
ProgressBar foot_bar; | |
public SearchAllInfoActivity() { | |
} | |
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
this.setContentView(2130903046); | |
this.mUtils = new MainUtils(this); | |
this.str_date = this.mUtils.getDate().substring(0, 7); | |
this.initPopupWindows(); | |
this.init(); | |
} | |
private void init() { | |
this.title_text = (TextView)this.findViewById(2131034202); | |
this.title_text.setText("本月支出记录"); | |
this.title_back = (Button)this.findViewById(2131034203); | |
this.title_back.setVisibility(0); | |
this.title_back.setOnClickListener(new OnClickListener() { | |
public void onClick(View v) { | |
SearchAllInfoActivity.this.finish(); | |
} | |
}); | |
this.mListView = (SwipeMenuListView)this.findViewById(2131034135); | |
this.setListView(); | |
this.adapter = new MySerchAdapter(this); | |
this.mListView.setAdapter(this.adapter); | |
this.getAllInfo(); | |
this.search_btn_all = (Button)this.findViewById(2131034136); | |
this.search_btn_all.setOnClickListener(new OnClickListener() { | |
public void onClick(View v) { | |
} | |
}); | |
} | |
private void setListView() { | |
SwipeMenuCreator creator = new SwipeMenuCreator() { | |
public void create(SwipeMenu menu) { | |
SearchAllInfoActivity.this.payItem = new SwipeMenuItem(SearchAllInfoActivity.this); | |
SearchAllInfoActivity.this.payItem.setBackground(new ColorDrawable(Color.rgb(4, 152, 216))); | |
SearchAllInfoActivity.this.payItem.setWidth(SearchAllInfoActivity.this.dp2px(120)); | |
SearchAllInfoActivity.this.payItem.setTitle("结算"); | |
SearchAllInfoActivity.this.payItem.setTitleSize(18); | |
SearchAllInfoActivity.this.payItem.setTitleColor(-1); | |
switch(menu.getViewType()) { | |
case 0: | |
menu.addMenuItem(SearchAllInfoActivity.this.payItem); | |
case 1: | |
default: | |
} | |
} | |
}; | |
this.mListView.setMenuCreator(creator); | |
this.view_list_foot = LayoutInflater.from(this).inflate(2130903049, (ViewGroup)null); | |
this.mListView.addFooterView(this.view_list_foot); | |
this.mListView.setOnScrollListener(new OnScrollListener() { | |
private int lastItemIndex; | |
public void onScrollStateChanged(AbsListView view, int scrollState) { | |
if(scrollState == 0 && this.lastItemIndex == SearchAllInfoActivity.this.adapter.getCount() - 1) { | |
SearchAllInfoActivity.this.getOtherInfo(); | |
} | |
} | |
public void onScroll(AbsListView view, int firstVisibleItem, int visibleItemCount, int totalItemCount) { | |
this.lastItemIndex = firstVisibleItem + visibleItemCount - 1 - 1; | |
} | |
}); | |
this.mListView.setOnMenuItemClickListener(new OnMenuItemClickListener() { | |
public boolean onMenuItemClick(int position, SwipeMenu menu, int index) { | |
SearchAllInfoActivity.this.showPopupWindow(position); | |
return false; | |
} | |
}); | |
} | |
private void getAllInfo() { | |
AVQuery query = new AVQuery("Expenses"); | |
query.whereMatches("date", this.str_date); | |
query.orderByDescending("eid"); | |
query.setLimit(this.firstGet); | |
query.findInBackground(new FindCallback() { | |
public void done(List<AVObject> avObjects, AVException e) { | |
if(e == null) { | |
Log.d("成功", "查询到" + avObjects.size() + " 条符合条件的数据"); | |
SearchAllInfoActivity.this.list = avObjects; | |
SearchAllInfoActivity.this.adapter.setData(SearchAllInfoActivity.this.list); | |
} else { | |
Log.d("失败", "查询失败"); | |
AllUtils.showToast(SearchAllInfoActivity.this, "查询错误"); | |
} | |
} | |
}); | |
} | |
public void getOtherInfo() { | |
this.foot_text = (TextView)this.view_list_foot.findViewById(2131034165); | |
this.foot_bar = (ProgressBar)this.view_list_foot.findViewById(2131034166); | |
this.foot_text.setText("正在加载..."); | |
this.foot_text.setVisibility(0); | |
this.foot_bar.setVisibility(0); | |
AVQuery query = new AVQuery("Expenses"); | |
query.whereMatches("date", this.str_date); | |
query.orderByDescending("eid"); | |
query.setLimit(this.nextGet); | |
query.setSkip(this.firstGet + this.nextGet * this.index); | |
query.findInBackground(new FindCallback() { | |
public void done(List<AVObject> avObjects, AVException e) { | |
if(e == null) { | |
if(avObjects.size() != 0) { | |
++SearchAllInfoActivity.this.index; | |
SearchAllInfoActivity.this.list.addAll(avObjects); | |
SearchAllInfoActivity.this.adapter.setData(SearchAllInfoActivity.this.list); | |
SearchAllInfoActivity.this.foot_text.setText("加载更多"); | |
SearchAllInfoActivity.this.foot_bar.setVisibility(8); | |
} else { | |
SearchAllInfoActivity.this.foot_text.setText("没有更多数据了"); | |
SearchAllInfoActivity.this.foot_bar.setVisibility(8); | |
} | |
} else { | |
Log.d("失败", "查询失败"); | |
AllUtils.showToast(SearchAllInfoActivity.this, "查询错误"); | |
} | |
} | |
}); | |
} | |
private void initPopupWindows() { | |
this.parent = this.findViewById(2131034133); | |
this.popView = this.getLayoutInflater().inflate(2130903051, (ViewGroup)null); | |
this.popupWindow = new PopupWindow(this.popView, -1, -2); | |
this.popupWindow.setBackgroundDrawable(new BitmapDrawable()); | |
this.popupWindow.setOutsideTouchable(true); | |
this.popup_text_date = (TextView)this.popView.findViewById(2131034177); | |
this.popup_text_money = (TextView)this.popView.findViewById(2131034179); | |
this.popup_text_who = (TextView)this.popView.findViewById(2131034182); | |
this.popup_text_yufu = (TextView)this.popView.findViewById(2131034185); | |
this.popup_btn_cancel = (Button)this.popView.findViewById(2131034172); | |
this.popup_btn_sure = (Button)this.popView.findViewById(2131034173); | |
this.popup_bar_wait = (ProgressBar)this.popView.findViewById(2131034186); | |
this.popup_btn_cancel.setOnClickListener(new OnClickListener() { | |
public void onClick(View v) { | |
SearchAllInfoActivity.this.popupWindow.dismiss(); | |
} | |
}); | |
} | |
private void showPopupWindow(int position) { | |
this.popupWindow.setAnimationStyle(2131361796); | |
this.popupWindow.showAtLocation(this.parent, 48, 0, 30); | |
AVObject av = (AVObject)this.list.get(position); | |
this.popup_text_date.setText(av.getString("date")); | |
this.popup_text_money.setText(av.getString("money")); | |
this.popup_text_who.setText(av.getString("who")); | |
this.popup_text_yufu.setText(av.getString("whopay")); | |
final String objectId = av.getObjectId(); | |
this.popup_btn_sure.setOnClickListener(new OnClickListener() { | |
public void onClick(View v) { | |
SearchAllInfoActivity.this.popup_btn_cancel.setVisibility(0); | |
SearchAllInfoActivity.this.updateState(objectId); | |
} | |
}); | |
} | |
private void updateState(String objectId) { | |
AVObject post = AVObject.createWithoutData("Expenses", objectId); | |
post.put("paystate", Boolean.valueOf(true)); | |
post.saveInBackground(new SaveCallback() { | |
public void done(AVException arg0) { | |
if(arg0 == null) { | |
AllUtils.showToast(SearchAllInfoActivity.this, "结算成功"); | |
SearchAllInfoActivity.this.popup_btn_cancel.setVisibility(0); | |
SearchAllInfoActivity.this.popupWindow.dismiss(); | |
SearchAllInfoActivity.this.getAllInfo(); | |
} else { | |
AllUtils.showToast(SearchAllInfoActivity.this, "结算失败,请重试"); | |
SearchAllInfoActivity.this.popup_btn_cancel.setVisibility(0); | |
} | |
} | |
}); | |
} | |
public int dp2px(int dp) { | |
return (int)TypedValue.applyDimension(1, (float)dp, this.getResources().getDisplayMetrics()); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import com.mysoft.myhome.activity.SearchPerInfoActivity; | |
class SearchPerInfoActivity$1 implements OnClickListener { | |
SearchPerInfoActivity$1(SearchPerInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(View v) { | |
this.this$0.finish(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.widget.AdapterView; | |
import android.widget.AdapterView.OnItemSelectedListener; | |
import com.mysoft.myhome.activity.SearchPerInfoActivity; | |
class SearchPerInfoActivity$2 implements OnItemSelectedListener { | |
SearchPerInfoActivity$2(SearchPerInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) { | |
SearchPerInfoActivity.access$0(this.this$0).setText(""); | |
this.this$0.str_name = this.this$0.array_who[position]; | |
SearchPerInfoActivity.access$1(this.this$0); | |
} | |
public void onNothingSelected(AdapterView<?> parent) { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.widget.AdapterView; | |
import android.widget.AdapterView.OnItemSelectedListener; | |
import com.mysoft.myhome.activity.SearchPerInfoActivity; | |
class SearchPerInfoActivity$3 implements OnItemSelectedListener { | |
SearchPerInfoActivity$3(SearchPerInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) { | |
this.this$0.str_paystate = this.this$0.array_pay_state[position]; | |
SearchPerInfoActivity.access$0(this.this$0).setText(""); | |
SearchPerInfoActivity.access$1(this.this$0); | |
} | |
public void onNothingSelected(AdapterView<?> parent) { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import com.mysoft.myhome.activity.SearchPerInfoActivity; | |
class SearchPerInfoActivity$4 implements OnClickListener { | |
SearchPerInfoActivity$4(SearchPerInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(View v) { | |
SearchPerInfoActivity.access$2(this.this$0); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.util.Log; | |
import com.avos.avoscloud.AVException; | |
import com.avos.avoscloud.AVObject; | |
import com.avos.avoscloud.FindCallback; | |
import com.mysoft.myhome.activity.SearchPerInfoActivity; | |
import com.mysoft.myhome.utils.AllUtils; | |
import java.util.List; | |
class SearchPerInfoActivity$5 extends FindCallback<AVObject> { | |
SearchPerInfoActivity$5(SearchPerInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void done(List<AVObject> avObjects, AVException e) { | |
if(e == null) { | |
this.this$0.list = avObjects; | |
this.this$0.adapter.setData(this.this$0.list); | |
double all_money = SearchPerInfoActivity.access$3(this.this$0); | |
SearchPerInfoActivity.access$4(this.this$0, Double.valueOf(all_money)); | |
} else { | |
Log.d("失败", "查询失败"); | |
AllUtils.showToast(this.this$0, "查询错误"); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.app.DatePickerDialog; | |
import android.content.DialogInterface; | |
import android.content.DialogInterface.OnClickListener; | |
import android.widget.DatePicker; | |
import com.mysoft.myhome.activity.SearchPerInfoActivity; | |
import java.text.SimpleDateFormat; | |
import java.util.Date; | |
class SearchPerInfoActivity$6 implements OnClickListener { | |
SearchPerInfoActivity$6(SearchPerInfoActivity var1, DatePickerDialog var2) { | |
this.this$0 = var1; | |
this.val$mDialog = var2; | |
} | |
public void onClick(DialogInterface dialog, int which) { | |
DatePicker datePicker = this.val$mDialog.getDatePicker(); | |
int year = datePicker.getYear(); | |
int month = datePicker.getMonth(); | |
int day = datePicker.getDayOfMonth(); | |
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM"); | |
Date date = new Date(year - 1900, month, day); | |
String str = dateFormat.format(date); | |
this.this$0.str_data = str; | |
SearchPerInfoActivity.access$5(this.this$0).setText(this.this$0.str_data); | |
SearchPerInfoActivity.access$1(this.this$0); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.content.DialogInterface; | |
import android.content.DialogInterface.OnClickListener; | |
import com.mysoft.myhome.activity.SearchPerInfoActivity; | |
class SearchPerInfoActivity$7 implements OnClickListener { | |
SearchPerInfoActivity$7(SearchPerInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(DialogInterface dialog, int which) { | |
dialog.dismiss(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.text.SpannableStringBuilder; | |
import android.text.style.ForegroundColorSpan; | |
import com.avos.avoscloud.AVException; | |
import com.avos.avoscloud.AVObject; | |
import com.avos.avoscloud.FindCallback; | |
import com.mysoft.myhome.activity.SearchPerInfoActivity; | |
import com.mysoft.myhome.utils.AllUtils; | |
import java.util.List; | |
class SearchPerInfoActivity$8 extends FindCallback<AVObject> { | |
SearchPerInfoActivity$8(SearchPerInfoActivity var1, Double var2) { | |
this.this$0 = var1; | |
this.val$money_exp = var2; | |
} | |
public void done(List<AVObject> arg0, AVException arg1) { | |
if(arg1 == null) { | |
double yufu_money = 0.0D; | |
if(arg0.size() > 0) { | |
for(int money_js = 0; money_js < arg0.size(); ++money_js) { | |
AVObject av_list = (AVObject)arg0.get(money_js); | |
double builder = Double.parseDouble(av_list.getString("money")); | |
yufu_money += builder; | |
} | |
} | |
SearchPerInfoActivity.access$6(this.this$0).setText(String.valueOf(yufu_money)); | |
double var9 = yufu_money - this.val$money_exp.doubleValue(); | |
if(var9 >= 0.0D) { | |
SpannableStringBuilder var10 = new SpannableStringBuilder("可取出" + var9); | |
ForegroundColorSpan redSpan = new ForegroundColorSpan(-65536); | |
var10.setSpan(redSpan, 3, var10.length(), 33); | |
SearchPerInfoActivity.access$7(this.this$0).setText(var10); | |
} else { | |
SearchPerInfoActivity.access$7(this.this$0).setText("需上交" + -var9); | |
} | |
} else { | |
AllUtils.showToast(this.this$0, "预付金额数据获取失败"); | |
arg1.printStackTrace(); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.app.DatePickerDialog; | |
import android.app.DatePickerDialog.OnDateSetListener; | |
import android.content.DialogInterface; | |
import android.os.Bundle; | |
import android.text.SpannableStringBuilder; | |
import android.text.style.ForegroundColorSpan; | |
import android.util.Log; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import android.widget.AdapterView; | |
import android.widget.Button; | |
import android.widget.DatePicker; | |
import android.widget.ListView; | |
import android.widget.Spinner; | |
import android.widget.TextView; | |
import android.widget.AdapterView.OnItemSelectedListener; | |
import com.avos.avoscloud.AVException; | |
import com.avos.avoscloud.AVObject; | |
import com.avos.avoscloud.AVQuery; | |
import com.avos.avoscloud.FindCallback; | |
import com.mysoft.myhome.activity.BaseActivity; | |
import com.mysoft.myhome.adapter.MySerchAdapter; | |
import com.mysoft.myhome.utils.AllUtils; | |
import com.mysoft.myhome.utils.MainUtils; | |
import java.text.SimpleDateFormat; | |
import java.util.Calendar; | |
import java.util.Date; | |
import java.util.List; | |
public class SearchPerInfoActivity extends BaseActivity { | |
private Button title_btn_back; | |
private TextView title_text_title; | |
private Spinner spinner_name; | |
private Spinner spinner_paystate; | |
private TextView text_date; | |
private ListView mListView; | |
private TextView text_money; | |
private TextView text_yufu; | |
private TextView text_jiesuan; | |
MySerchAdapter adapter; | |
List<AVObject> list; | |
String str_name = "全部"; | |
String str_paystate = "未结算"; | |
String str_data; | |
String[] array_who; | |
String[] array_pay_state; | |
MainUtils mainUtils; | |
public SearchPerInfoActivity() { | |
} | |
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
this.setContentView(2130903047); | |
this.mainUtils = new MainUtils(this); | |
this.init(); | |
this.searchInfo(); | |
} | |
private void init() { | |
this.title_btn_back = (Button)this.findViewById(2131034203); | |
this.title_btn_back.setVisibility(0); | |
this.title_btn_back.setOnClickListener(new OnClickListener() { | |
public void onClick(View v) { | |
SearchPerInfoActivity.this.finish(); | |
} | |
}); | |
this.title_text_title = (TextView)this.findViewById(2131034202); | |
this.title_text_title.setText("搜索"); | |
this.text_yufu = (TextView)this.findViewById(2131034147); | |
this.text_jiesuan = (TextView)this.findViewById(2131034149); | |
this.mListView = (ListView)this.findViewById(2131034150); | |
this.adapter = new MySerchAdapter(this); | |
this.mListView.setAdapter(this.adapter); | |
this.array_who = this.getResources().getStringArray(2131296257); | |
this.array_pay_state = this.getResources().getStringArray(2131296258); | |
this.spinner_name = (Spinner)this.findViewById(2131034140); | |
this.spinner_name.setOnItemSelectedListener(new OnItemSelectedListener() { | |
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) { | |
SearchPerInfoActivity.this.text_money.setText(""); | |
SearchPerInfoActivity.this.str_name = SearchPerInfoActivity.this.array_who[position]; | |
SearchPerInfoActivity.this.searchInfo(); | |
} | |
public void onNothingSelected(AdapterView<?> parent) { | |
} | |
}); | |
this.spinner_paystate = (Spinner)this.findViewById(2131034141); | |
this.spinner_paystate.setOnItemSelectedListener(new OnItemSelectedListener() { | |
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) { | |
SearchPerInfoActivity.this.str_paystate = SearchPerInfoActivity.this.array_pay_state[position]; | |
SearchPerInfoActivity.this.text_money.setText(""); | |
SearchPerInfoActivity.this.searchInfo(); | |
} | |
public void onNothingSelected(AdapterView<?> parent) { | |
} | |
}); | |
this.text_date = (TextView)this.findViewById(2131034142); | |
this.str_data = this.text_date.getText().toString(); | |
this.text_date.setOnClickListener(new OnClickListener() { | |
public void onClick(View v) { | |
SearchPerInfoActivity.this.showDatePicker(); | |
} | |
}); | |
this.text_money = (TextView)this.findViewById(2131034145); | |
} | |
private void searchInfo() { | |
AVQuery query = new AVQuery("Expenses"); | |
query.whereMatches("date", this.str_data.substring(0, 7)); | |
query.whereEqualTo("paystate", Boolean.valueOf(!this.str_paystate.equals("未结算"))); | |
query.orderByDescending("eid"); | |
if(!this.str_name.equals("全部")) { | |
query.whereMatches("who", this.str_name); | |
} | |
this.adapter.setName(this.str_name); | |
query.findInBackground(new FindCallback() { | |
public void done(List<AVObject> avObjects, AVException e) { | |
if(e == null) { | |
SearchPerInfoActivity.this.list = avObjects; | |
SearchPerInfoActivity.this.adapter.setData(SearchPerInfoActivity.this.list); | |
double all_money = SearchPerInfoActivity.this.getMoney(); | |
SearchPerInfoActivity.this.getYuFu(Double.valueOf(all_money)); | |
} else { | |
Log.d("失败", "查询失败"); | |
AllUtils.showToast(SearchPerInfoActivity.this, "查询错误"); | |
} | |
} | |
}); | |
} | |
private void showDatePicker() { | |
Calendar cal = Calendar.getInstance(); | |
final DatePickerDialog mDialog = new DatePickerDialog(this, (OnDateSetListener)null, cal.get(1), cal.get(2), cal.get(5)); | |
mDialog.setButton(-1, "完成", new android.content.DialogInterface.OnClickListener() { | |
public void onClick(DialogInterface dialog, int which) { | |
DatePicker datePicker = mDialog.getDatePicker(); | |
int year = datePicker.getYear(); | |
int month = datePicker.getMonth(); | |
int day = datePicker.getDayOfMonth(); | |
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM"); | |
Date date = new Date(year - 1900, month, day); | |
String str = dateFormat.format(date); | |
SearchPerInfoActivity.this.str_data = str; | |
SearchPerInfoActivity.this.text_date.setText(SearchPerInfoActivity.this.str_data); | |
SearchPerInfoActivity.this.searchInfo(); | |
} | |
}); | |
mDialog.setCancelable(true); | |
mDialog.setCanceledOnTouchOutside(true); | |
mDialog.setButton(-3, "取消", new android.content.DialogInterface.OnClickListener() { | |
public void onClick(DialogInterface dialog, int which) { | |
dialog.dismiss(); | |
} | |
}); | |
mDialog.show(); | |
} | |
private double getMoney() { | |
double allmoney = 0.0D; | |
if(this.list.size() > 0) { | |
int i; | |
AVObject avlist; | |
double money; | |
if(this.str_name.equals("全部")) { | |
for(i = 0; i < this.list.size(); ++i) { | |
avlist = (AVObject)this.list.get(i); | |
money = Double.parseDouble(avlist.getString("money")); | |
allmoney += money; | |
} | |
} else { | |
for(i = 0; i < this.list.size(); ++i) { | |
avlist = (AVObject)this.list.get(i); | |
money = Double.parseDouble(avlist.getString("avgpay")); | |
allmoney += money; | |
} | |
} | |
} | |
this.text_money.setText(String.valueOf(allmoney)); | |
return allmoney; | |
} | |
private void getYuFu(final Double money_exp) { | |
AVQuery query = new AVQuery("Expenses"); | |
query.whereMatches("date", this.str_data.substring(0, 7)); | |
query.whereEqualTo("paystate", Boolean.valueOf(!this.str_paystate.equals("未结算"))); | |
query.orderByDescending("eid"); | |
if(this.str_name.equals("全部")) { | |
query.whereMatches("whopay", "舍费"); | |
} else { | |
query.whereMatches("whopay", this.str_name); | |
} | |
query.findInBackground(new FindCallback() { | |
public void done(List<AVObject> arg0, AVException arg1) { | |
if(arg1 == null) { | |
double yufu_money = 0.0D; | |
if(arg0.size() > 0) { | |
for(int money_js = 0; money_js < arg0.size(); ++money_js) { | |
AVObject av_list = (AVObject)arg0.get(money_js); | |
double builder = Double.parseDouble(av_list.getString("money")); | |
yufu_money += builder; | |
} | |
} | |
SearchPerInfoActivity.this.text_yufu.setText(String.valueOf(yufu_money)); | |
double var9 = yufu_money - money_exp.doubleValue(); | |
if(var9 >= 0.0D) { | |
SpannableStringBuilder var10 = new SpannableStringBuilder("可取出" + var9); | |
ForegroundColorSpan redSpan = new ForegroundColorSpan(-65536); | |
var10.setSpan(redSpan, 3, var10.length(), 33); | |
SearchPerInfoActivity.this.text_jiesuan.setText(var10); | |
} else { | |
SearchPerInfoActivity.this.text_jiesuan.setText("需上交" + -var9); | |
} | |
} else { | |
AllUtils.showToast(SearchPerInfoActivity.this, "预付金额数据获取失败"); | |
arg1.printStackTrace(); | |
} | |
} | |
}); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
class SubmitInfoActivity$1 implements OnClickListener { | |
SubmitInfoActivity$1(SubmitInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(View v) { | |
this.this$0.finish(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.content.DialogInterface; | |
import android.content.DialogInterface.OnClickListener; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
class SubmitInfoActivity$10 implements OnClickListener { | |
SubmitInfoActivity$10(SubmitInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(DialogInterface dialog, int which) { | |
dialog.dismiss(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import com.avos.avoscloud.AVException; | |
import com.avos.avoscloud.SaveCallback; | |
import com.mysoft.myhome.activity.SubmitInfoActivity.11; | |
class SubmitInfoActivity$11$1 extends SaveCallback { | |
SubmitInfoActivity$11$1(11 var1) { | |
this.this$1 = var1; | |
} | |
public void done(AVException arg0) { | |
if(arg0 == null) { | |
11.access$0(this.this$1).mUtils.showToast("保存成功"); | |
11.access$0(this.this$1).finish(); | |
} else { | |
11.access$0(this.this$1).mUtils.showToast("保存失败,请重试"); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.content.DialogInterface; | |
import android.content.DialogInterface.OnClickListener; | |
import com.avos.avoscloud.AVObject; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
import com.mysoft.myhome.activity.SubmitInfoActivity$11$1; | |
class SubmitInfoActivity$11 implements OnClickListener { | |
SubmitInfoActivity$11(SubmitInfoActivity var1, AVObject var2) { | |
this.this$0 = var1; | |
this.val$post = var2; | |
} | |
public void onClick(DialogInterface dialog, int which) { | |
this.val$post.saveInBackground(new SubmitInfoActivity$11$1(this)); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.content.DialogInterface; | |
import android.content.DialogInterface.OnClickListener; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
class SubmitInfoActivity$12 implements OnClickListener { | |
SubmitInfoActivity$12(SubmitInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(DialogInterface dialog, int which) { | |
dialog.dismiss(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
class SubmitInfoActivity$2 implements OnClickListener { | |
SubmitInfoActivity$2(SubmitInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(View v) { | |
SubmitInfoActivity.access$0(this.this$0); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.widget.AdapterView; | |
import android.widget.AdapterView.OnItemSelectedListener; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
class SubmitInfoActivity$3 implements OnItemSelectedListener { | |
SubmitInfoActivity$3(SubmitInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onItemSelected(AdapterView<?> arg0, View arg1, int arg2, long arg3) { | |
this.this$0.str_who_pay = this.this$0.languages[arg2]; | |
} | |
public void onNothingSelected(AdapterView<?> arg0) { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
class SubmitInfoActivity$4 implements OnClickListener { | |
SubmitInfoActivity$4(SubmitInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(View v) { | |
SubmitInfoActivity.access$1(this.this$0).setAnimationStyle(2131361795); | |
SubmitInfoActivity.access$1(this.this$0).showAtLocation(SubmitInfoActivity.access$2(this.this$0), 17, 0, 0); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.widget.AdapterView; | |
import android.widget.ImageView; | |
import android.widget.TextView; | |
import android.widget.AdapterView.OnItemClickListener; | |
import com.mysoft.myhome.HumanBean; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
class SubmitInfoActivity$5 implements OnItemClickListener { | |
SubmitInfoActivity$5(SubmitInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onItemClick(AdapterView<?> parent, View view, int position, long id) { | |
HumanBean bean = null; | |
ImageView img = (ImageView)view.findViewById(2131034169); | |
TextView text_name = (TextView)view.findViewById(2131034168); | |
String name = text_name.getText().toString().trim(); | |
if(!SubmitInfoActivity.access$3(this.this$0, name)) { | |
bean = new HumanBean(); | |
bean.setName(name); | |
this.this$0.list.add(bean); | |
} else { | |
bean = SubmitInfoActivity.access$4(this.this$0, name); | |
} | |
if(img.getVisibility() == 8) { | |
img.setVisibility(0); | |
bean.setChoice(true); | |
} else if(img.getVisibility() == 0) { | |
img.setVisibility(8); | |
bean.setChoice(false); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
class SubmitInfoActivity$6 implements OnClickListener { | |
SubmitInfoActivity$6(SubmitInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(View v) { | |
SubmitInfoActivity.access$5(this.this$0); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
class SubmitInfoActivity$7 implements OnClickListener { | |
SubmitInfoActivity$7(SubmitInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(View v) { | |
SubmitInfoActivity.access$1(this.this$0).dismiss(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.view.View; | |
import android.view.View.OnClickListener; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
class SubmitInfoActivity$8 implements OnClickListener { | |
SubmitInfoActivity$8(SubmitInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onClick(View v) { | |
this.this$0.str_note = SubmitInfoActivity.access$6(this.this$0).getText().toString().trim(); | |
SubmitInfoActivity.access$1(this.this$0).dismiss(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.app.DatePickerDialog.OnDateSetListener; | |
import android.widget.DatePicker; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
import java.text.SimpleDateFormat; | |
import java.util.Date; | |
class SubmitInfoActivity$9 implements OnDateSetListener { | |
SubmitInfoActivity$9(SubmitInfoActivity var1) { | |
this.this$0 = var1; | |
} | |
public void onDateSet(DatePicker view, int year, int monthOfYear, int dayOfMonth) { | |
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd"); | |
Date date = new Date(year - 1900, monthOfYear, dayOfMonth); | |
String str = dateFormat.format(date); | |
SubmitInfoActivity.access$7(this.this$0).setText(str); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.activity; | |
import android.app.DatePickerDialog; | |
import android.app.AlertDialog.Builder; | |
import android.app.DatePickerDialog.OnDateSetListener; | |
import android.content.DialogInterface; | |
import android.graphics.Bitmap; | |
import android.graphics.drawable.BitmapDrawable; | |
import android.os.Bundle; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.view.View.OnClickListener; | |
import android.widget.AdapterView; | |
import android.widget.Button; | |
import android.widget.DatePicker; | |
import android.widget.EditText; | |
import android.widget.GridView; | |
import android.widget.ImageView; | |
import android.widget.PopupWindow; | |
import android.widget.Spinner; | |
import android.widget.TextView; | |
import android.widget.AdapterView.OnItemClickListener; | |
import android.widget.AdapterView.OnItemSelectedListener; | |
import com.avos.avoscloud.AVException; | |
import com.avos.avoscloud.AVObject; | |
import com.avos.avoscloud.SaveCallback; | |
import com.mysoft.myhome.HumanBean; | |
import com.mysoft.myhome.activity.BaseActivity; | |
import com.mysoft.myhome.adapter.MyGridAdapter; | |
import com.mysoft.myhome.utils.AllUtils; | |
import com.mysoft.myhome.utils.MainUtils; | |
import java.text.SimpleDateFormat; | |
import java.util.ArrayList; | |
import java.util.Calendar; | |
import java.util.Date; | |
import java.util.Locale; | |
public class SubmitInfoActivity extends BaseActivity { | |
private TextView title_text; | |
private Button title_btn_back; | |
private Spinner spinner_whopay; | |
private Button btn_add_note; | |
private TextView text_date; | |
private EditText edit_money; | |
private Button btn_sure; | |
private GridView mGridView; | |
private PopupWindow popupWindow; | |
private View popView; | |
private View parent; | |
private Button btn_pop_cancle; | |
private Button btn_pop_sure; | |
private EditText edit_pop_note; | |
ArrayList<HumanBean> list = new ArrayList(); | |
MyGridAdapter adapter; | |
MainUtils mUtils; | |
String str; | |
String str_who_pay; | |
double money; | |
String[] languages; | |
ArrayList<String> list_names = new ArrayList(); | |
ArrayList<Bitmap> list_imgs = new ArrayList(); | |
String str_note = ""; | |
public SubmitInfoActivity() { | |
} | |
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
this.setContentView(2130903048); | |
this.mUtils = new MainUtils(this); | |
this.str = this.mUtils.getDate(); | |
this.parent = this.findViewById(2131034151); | |
this.initPopupWindows(); | |
this.init(); | |
} | |
private void init() { | |
this.title_text = (TextView)this.findViewById(2131034202); | |
this.title_text.setText("记账"); | |
this.title_btn_back = (Button)this.findViewById(2131034203); | |
this.title_btn_back.setVisibility(0); | |
this.title_btn_back.setOnClickListener(new OnClickListener() { | |
public void onClick(View v) { | |
SubmitInfoActivity.this.finish(); | |
} | |
}); | |
this.text_date = (TextView)this.findViewById(2131034154); | |
this.text_date.setText(this.str); | |
this.text_date.setOnClickListener(new OnClickListener() { | |
public void onClick(View v) { | |
SubmitInfoActivity.this.showDatePicker(); | |
} | |
}); | |
this.edit_money = (EditText)this.findViewById(2131034157); | |
this.languages = this.getResources().getStringArray(2131296256); | |
this.str_who_pay = this.languages[0]; | |
this.spinner_whopay = (Spinner)this.findViewById(2131034160); | |
this.spinner_whopay.setOnItemSelectedListener(new OnItemSelectedListener() { | |
public void onItemSelected(AdapterView<?> arg0, View arg1, int arg2, long arg3) { | |
SubmitInfoActivity.this.str_who_pay = SubmitInfoActivity.this.languages[arg2]; | |
} | |
public void onNothingSelected(AdapterView<?> arg0) { | |
} | |
}); | |
this.btn_add_note = (Button)this.findViewById(2131034161); | |
this.btn_add_note.setOnClickListener(new OnClickListener() { | |
public void onClick(View v) { | |
SubmitInfoActivity.this.popupWindow.setAnimationStyle(2131361795); | |
SubmitInfoActivity.this.popupWindow.showAtLocation(SubmitInfoActivity.this.parent, 17, 0, 0); | |
} | |
}); | |
this.mGridView = (GridView)this.findViewById(2131034163); | |
this.adapter = new MyGridAdapter(this); | |
this.mGridView.setAdapter(this.adapter); | |
this.mGridView.setOnItemClickListener(new OnItemClickListener() { | |
public void onItemClick(AdapterView<?> parent, View view, int position, long id) { | |
HumanBean bean = null; | |
ImageView img = (ImageView)view.findViewById(2131034169); | |
TextView text_name = (TextView)view.findViewById(2131034168); | |
String name = text_name.getText().toString().trim(); | |
if(!SubmitInfoActivity.this.isSame(name)) { | |
bean = new HumanBean(); | |
bean.setName(name); | |
SubmitInfoActivity.this.list.add(bean); | |
} else { | |
bean = SubmitInfoActivity.this.getNameBean(name); | |
} | |
if(img.getVisibility() == 8) { | |
img.setVisibility(0); | |
bean.setChoice(true); | |
} else if(img.getVisibility() == 0) { | |
img.setVisibility(8); | |
bean.setChoice(false); | |
} | |
} | |
}); | |
this.btn_sure = (Button)this.findViewById(2131034164); | |
this.btn_sure.setOnClickListener(new OnClickListener() { | |
public void onClick(View v) { | |
SubmitInfoActivity.this.submitData(); | |
} | |
}); | |
} | |
private void initPopupWindows() { | |
this.popView = this.getLayoutInflater().inflate(2130903052, (ViewGroup)null); | |
this.popupWindow = new PopupWindow(this.popView, -1, -2); | |
this.popupWindow.setFocusable(true); | |
this.popupWindow.setBackgroundDrawable(new BitmapDrawable()); | |
this.popupWindow.setOutsideTouchable(true); | |
this.edit_pop_note = (EditText)this.popView.findViewById(2131034188); | |
this.btn_pop_cancle = (Button)this.popView.findViewById(2131034190); | |
this.btn_pop_cancle.setOnClickListener(new OnClickListener() { | |
public void onClick(View v) { | |
SubmitInfoActivity.this.popupWindow.dismiss(); | |
} | |
}); | |
this.btn_pop_sure = (Button)this.popView.findViewById(2131034191); | |
this.btn_pop_sure.setOnClickListener(new OnClickListener() { | |
public void onClick(View v) { | |
SubmitInfoActivity.this.str_note = SubmitInfoActivity.this.edit_pop_note.getText().toString().trim(); | |
SubmitInfoActivity.this.popupWindow.dismiss(); | |
} | |
}); | |
} | |
private void showDatePicker() { | |
Calendar d = Calendar.getInstance(Locale.CHINA); | |
Date myDate = new Date(); | |
d.setTime(myDate); | |
int year = d.get(1); | |
int month = d.get(2); | |
int day = d.get(5); | |
DatePickerDialog dialog = new DatePickerDialog(this, new OnDateSetListener() { | |
public void onDateSet(DatePicker view, int year, int monthOfYear, int dayOfMonth) { | |
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd"); | |
Date date = new Date(year - 1900, monthOfYear, dayOfMonth); | |
String str = dateFormat.format(date); | |
SubmitInfoActivity.this.text_date.setText(str); | |
} | |
}, year, month, day); | |
dialog.setCancelable(true); | |
dialog.setCanceledOnTouchOutside(true); | |
dialog.setButton(-3, "取消", new android.content.DialogInterface.OnClickListener() { | |
public void onClick(DialogInterface dialog, int which) { | |
dialog.dismiss(); | |
} | |
}); | |
dialog.show(); | |
} | |
private boolean isSame(String name) { | |
for(int i = 0; i < this.list.size(); ++i) { | |
if(name.equals(((HumanBean)this.list.get(i)).getName())) { | |
return true; | |
} | |
} | |
return false; | |
} | |
private HumanBean getNameBean(String name) { | |
HumanBean mybean = new HumanBean(); | |
for(int i = 0; i < this.list.size(); ++i) { | |
if(name.equals(((HumanBean)this.list.get(i)).getName())) { | |
mybean = (HumanBean)this.list.get(i); | |
} | |
} | |
return mybean; | |
} | |
private void submitData() { | |
String str_money = this.edit_money.getText().toString().trim(); | |
try { | |
this.money = Double.parseDouble(str_money); | |
int e = 0; | |
String str_people = ""; | |
for(int date = 0; date < this.list.size(); ++date) { | |
if(((HumanBean)this.list.get(date)).isChoice()) { | |
++e; | |
str_people = str_people + ((HumanBean)this.list.get(date)).getName() + ","; | |
} | |
} | |
if(!str_people.equals("")) { | |
str_people = str_people.substring(0, str_people.length() - 1); | |
} | |
String var7 = this.text_date.getText().toString(); | |
AVObject post = new AVObject("Expenses"); | |
post.put("date", var7); | |
post.put("money", String.valueOf(this.money)); | |
post.put("count", Integer.valueOf(e)); | |
post.put("who", str_people); | |
post.put("whopay", this.str_who_pay); | |
post.put("avgpay", String.format("%.2f", new Object[]{Double.valueOf(this.money / (double)e)})); | |
post.put("note", this.str_note); | |
this.showSubDialog(post); | |
} catch (Exception var6) { | |
AllUtils.showToast(this, "金额不能为空"); | |
} | |
} | |
private void showSubDialog(final AVObject post) { | |
Builder dialog = new Builder(this); | |
dialog.setTitle("提交"); | |
dialog.setMessage("是否提交本次记账"); | |
dialog.setPositiveButton("是", new android.content.DialogInterface.OnClickListener() { | |
public void onClick(DialogInterface dialog, int which) { | |
post.saveInBackground(new SaveCallback() { | |
public void done(AVException arg0) { | |
if(arg0 == null) { | |
SubmitInfoActivity.this.mUtils.showToast("保存成功"); | |
SubmitInfoActivity.this.finish(); | |
} else { | |
SubmitInfoActivity.this.mUtils.showToast("保存失败,请重试"); | |
} | |
} | |
}); | |
} | |
}); | |
dialog.setNegativeButton("否", new android.content.DialogInterface.OnClickListener() { | |
public void onClick(DialogInterface dialog, int which) { | |
dialog.dismiss(); | |
} | |
}); | |
dialog.create().show(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.adapter; | |
import android.view.View; | |
import android.widget.ImageView; | |
import android.widget.TextView; | |
import com.mysoft.myhome.adapter.HomeGridAdapter; | |
class HomeGridAdapter$ViewHolder { | |
TextView menu_text; | |
ImageView menu_icon; | |
public HomeGridAdapter$ViewHolder(HomeGridAdapter var1, View view) { | |
this.this$0 = var1; | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.adapter; | |
import android.content.Context; | |
import android.view.LayoutInflater; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.widget.BaseAdapter; | |
import android.widget.ImageView; | |
import android.widget.TextView; | |
public class HomeGridAdapter extends BaseAdapter { | |
LayoutInflater layout; | |
String[] strs = new String[]{"添加数据", "查询数据", "添加数据", "查询数据", "添加数据", "查询数据"}; | |
public HomeGridAdapter(Context context) { | |
this.layout = LayoutInflater.from(context); | |
} | |
public int getCount() { | |
return 6; | |
} | |
public Object getItem(int position) { | |
return null; | |
} | |
public long getItemId(int position) { | |
return 0L; | |
} | |
public View getView(int position, View convertView, ViewGroup parent) { | |
return convertView; | |
} | |
class ViewHolder { | |
TextView menu_text; | |
ImageView menu_icon; | |
public ViewHolder(View view) { | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.adapter; | |
import android.view.View; | |
import android.widget.ImageView; | |
import android.widget.TextView; | |
import com.mysoft.myhome.adapter.MyGridAdapter; | |
import com.mysoft.myhome.view.RoundImageView; | |
class MyGridAdapter$MyViewHolder { | |
TextView mTextView; | |
ImageView img_choice; | |
RoundImageView img_touxiang; | |
public MyGridAdapter$MyViewHolder(MyGridAdapter var1, View view) { | |
this.this$0 = var1; | |
this.mTextView = (TextView)view.findViewById(2131034168); | |
this.img_choice = (ImageView)view.findViewById(2131034169); | |
this.img_touxiang = (RoundImageView)view.findViewById(2131034167); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.adapter; | |
import android.content.Context; | |
import android.graphics.Bitmap; | |
import android.graphics.BitmapFactory; | |
import android.view.LayoutInflater; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.widget.BaseAdapter; | |
import android.widget.ImageView; | |
import android.widget.TextView; | |
import com.mysoft.myhome.utils.ACache; | |
import com.mysoft.myhome.utils.MyPreferences; | |
import com.mysoft.myhome.view.RoundImageView; | |
import java.util.ArrayList; | |
import java.util.HashSet; | |
import java.util.Set; | |
public class MyGridAdapter extends BaseAdapter { | |
LayoutInflater layout; | |
MyGridAdapter.MyViewHolder holder; | |
Context context; | |
ArrayList<String> list_names = new ArrayList(); | |
ArrayList<Bitmap> list_imgs = new ArrayList(); | |
Set<String> siteno = new HashSet(); | |
private ACache mCache; | |
MyPreferences preferences; | |
String[] ss = new String[]{"群英", "李榕", "金玉", "毅华", "庄宏展"}; | |
public MyGridAdapter(Context context) { | |
this.layout = LayoutInflater.from(context); | |
this.preferences = new MyPreferences(context); | |
this.mCache = ACache.get(context); | |
this.context = context; | |
this.setList(); | |
} | |
public void setList() { | |
this.siteno = this.preferences.getList("302home"); | |
this.list_names = new ArrayList(this.siteno); | |
for(int i = 0; i < this.siteno.size(); ++i) { | |
Bitmap testBitmap = this.mCache.getAsBitmap((String)this.list_names.get(i)); | |
if(testBitmap == null) { | |
testBitmap = BitmapFactory.decodeResource(this.context.getResources(), 2130837547); | |
} | |
this.list_imgs.add(testBitmap); | |
} | |
} | |
public void setImgs(ArrayList<Bitmap> list_imgs) { | |
this.list_imgs = list_imgs; | |
} | |
public int getCount() { | |
return this.list_names.size() == 0?this.ss.length:this.list_names.size(); | |
} | |
public Object getItem(int position) { | |
return null; | |
} | |
public long getItemId(int position) { | |
return 0L; | |
} | |
public View getView(int position, View convertView, ViewGroup parent) { | |
if(convertView == null) { | |
convertView = this.layout.inflate(2130903050, (ViewGroup)null); | |
this.holder = new MyGridAdapter.MyViewHolder(convertView); | |
convertView.setTag(this.holder); | |
} else { | |
this.holder = (MyGridAdapter.MyViewHolder)convertView.getTag(); | |
} | |
this.holder.mTextView.setText((CharSequence)this.list_names.get(position)); | |
this.holder.img_touxiang.setImageBitmap((Bitmap)this.list_imgs.get(position)); | |
return convertView; | |
} | |
class MyViewHolder { | |
TextView mTextView; | |
ImageView img_choice; | |
RoundImageView img_touxiang; | |
public MyViewHolder(View view) { | |
this.mTextView = (TextView)view.findViewById(2131034168); | |
this.img_choice = (ImageView)view.findViewById(2131034169); | |
this.img_touxiang = (RoundImageView)view.findViewById(2131034167); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.adapter; | |
import android.view.View; | |
import android.widget.RelativeLayout; | |
import android.widget.TextView; | |
import com.mysoft.myhome.adapter.MySerchAdapter; | |
class MySerchAdapter$MyViewHolder { | |
TextView text_date; | |
TextView text_money; | |
TextView text_who; | |
TextView text_state; | |
TextView text_whopay; | |
RelativeLayout mRelativeLayout; | |
TextView text_note; | |
public MySerchAdapter$MyViewHolder(MySerchAdapter var1, View view) { | |
this.this$0 = var1; | |
this.text_date = (TextView)view.findViewById(2131034193); | |
this.text_money = (TextView)view.findViewById(2131034194); | |
this.text_who = (TextView)view.findViewById(2131034195); | |
this.text_state = (TextView)view.findViewById(2131034201); | |
this.text_whopay = (TextView)view.findViewById(2131034200); | |
this.mRelativeLayout = (RelativeLayout)view.findViewById(2131034196); | |
this.text_note = (TextView)view.findViewById(2131034198); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.adapter; | |
import android.content.Context; | |
import android.graphics.Color; | |
import android.text.SpannableStringBuilder; | |
import android.text.style.ForegroundColorSpan; | |
import android.view.LayoutInflater; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.widget.BaseAdapter; | |
import android.widget.RelativeLayout; | |
import android.widget.TextView; | |
import com.avos.avoscloud.AVObject; | |
import java.util.ArrayList; | |
import java.util.List; | |
public class MySerchAdapter extends BaseAdapter { | |
LayoutInflater layout; | |
List<AVObject> avObjects = new ArrayList(); | |
MySerchAdapter.MyViewHolder holder; | |
Context context; | |
String str_name; | |
public MySerchAdapter(Context context) { | |
this.layout = LayoutInflater.from(context); | |
this.context = context; | |
this.str_name = ""; | |
} | |
public void setName(String str_name) { | |
this.str_name = str_name; | |
} | |
public void setData(List<AVObject> avObjects) { | |
this.avObjects = avObjects; | |
this.notifyDataSetChanged(); | |
} | |
public int getCount() { | |
return this.avObjects.size(); | |
} | |
public Object getItem(int position) { | |
return null; | |
} | |
public long getItemId(int position) { | |
return 0L; | |
} | |
public int getViewTypeCount() { | |
return 2; | |
} | |
public int getItemViewType(int position) { | |
AVObject list = (AVObject)this.avObjects.get(position); | |
boolean state = list.getBoolean("paystate"); | |
return state?1:0; | |
} | |
public View getView(int position, View convertView, ViewGroup parent) { | |
if(convertView == null) { | |
convertView = this.layout.inflate(2130903053, (ViewGroup)null); | |
this.holder = new MySerchAdapter.MyViewHolder(convertView); | |
convertView.setTag(this.holder); | |
} else { | |
this.holder = (MySerchAdapter.MyViewHolder)convertView.getTag(); | |
} | |
AVObject list = (AVObject)this.avObjects.get(position); | |
this.holder.text_date.setText(list.getString("date")); | |
this.holder.text_money.setText(list.getString("money")); | |
if(!this.str_name.equals("")) { | |
SpannableStringBuilder state = new SpannableStringBuilder(list.getString("who")); | |
ForegroundColorSpan str_whopay = new ForegroundColorSpan(-65536); | |
int str_note = list.getString("who").indexOf(this.str_name); | |
if(str_note != -1) { | |
state.setSpan(str_whopay, str_note, str_note + this.str_name.length(), 33); | |
this.holder.text_who.setText(state); | |
} | |
if(this.str_name.equals("全部")) { | |
this.holder.text_who.setText(list.getString("who")); | |
} | |
} else { | |
this.holder.text_who.setText(list.getString("who")); | |
} | |
boolean state1 = list.getBoolean("paystate"); | |
if(state1) { | |
this.holder.text_state.setText("已结算"); | |
} else { | |
this.holder.text_state.setText("未结算"); | |
this.holder.text_state.setTextColor(Color.rgb(4, 152, 216)); | |
} | |
String str_whopay1 = list.getString("whopay"); | |
if(str_whopay1 != null) { | |
this.holder.text_whopay.setText(str_whopay1); | |
} else { | |
this.holder.text_whopay.setText(""); | |
} | |
String str_note1 = list.getString("note"); | |
if(str_note1 != null && !str_note1.equals("")) { | |
this.holder.mRelativeLayout.setVisibility(0); | |
this.holder.text_note.setText(str_note1); | |
} else { | |
this.holder.mRelativeLayout.setVisibility(8); | |
} | |
return convertView; | |
} | |
class MyViewHolder { | |
TextView text_date; | |
TextView text_money; | |
TextView text_who; | |
TextView text_state; | |
TextView text_whopay; | |
RelativeLayout mRelativeLayout; | |
TextView text_note; | |
public MyViewHolder(View view) { | |
this.text_date = (TextView)view.findViewById(2131034193); | |
this.text_money = (TextView)view.findViewById(2131034194); | |
this.text_who = (TextView)view.findViewById(2131034195); | |
this.text_state = (TextView)view.findViewById(2131034201); | |
this.text_whopay = (TextView)view.findViewById(2131034200); | |
this.mRelativeLayout = (RelativeLayout)view.findViewById(2131034196); | |
this.text_note = (TextView)view.findViewById(2131034198); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class BuildConfig { | |
public static final boolean DEBUG = Boolean.parseBoolean((String)null); | |
public BuildConfig() { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.fragment; | |
import android.content.Intent; | |
import android.os.Bundle; | |
import android.support.v4.app.Fragment; | |
import android.view.LayoutInflater; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.view.View.OnClickListener; | |
import android.widget.Button; | |
import android.widget.TextView; | |
import com.mysoft.myhome.activity.SearchAllInfoActivity; | |
import com.mysoft.myhome.activity.SearchPerInfoActivity; | |
import com.mysoft.myhome.activity.SubmitInfoActivity; | |
public class Fragment_Home extends Fragment implements OnClickListener { | |
private View cView; | |
private TextView title_text; | |
private Button menu_btn_1; | |
private Button menu_btn_2; | |
private Button menu_btn_3; | |
public Fragment_Home() { | |
} | |
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { | |
if(this.cView == null) { | |
this.cView = inflater.inflate(2130903041, container, false); | |
} | |
this.init(); | |
return this.cView; | |
} | |
private void init() { | |
this.title_text = (TextView)this.cView.findViewById(2131034202); | |
this.title_text.setText("302理财"); | |
this.menu_btn_1 = (Button)this.cView.findViewById(2131034122); | |
this.menu_btn_2 = (Button)this.cView.findViewById(2131034125); | |
this.menu_btn_3 = (Button)this.cView.findViewById(2131034128); | |
this.menu_btn_1.setOnClickListener(this); | |
this.menu_btn_2.setOnClickListener(this); | |
this.menu_btn_3.setOnClickListener(this); | |
} | |
public void onClick(View v) { | |
switch(v.getId()) { | |
case 2131034122: | |
Intent it_sub = new Intent(this.getActivity(), SubmitInfoActivity.class); | |
this.startActivity(it_sub); | |
case 2131034123: | |
case 2131034124: | |
case 2131034126: | |
case 2131034127: | |
default: | |
break; | |
case 2131034125: | |
Intent it_search = new Intent(this.getActivity(), SearchAllInfoActivity.class); | |
this.startActivity(it_search); | |
break; | |
case 2131034128: | |
Intent it_perinfo = new Intent(this.getActivity(), SearchPerInfoActivity.class); | |
this.startActivity(it_perinfo); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.fragment; | |
import android.os.Bundle; | |
import android.support.v4.app.Fragment; | |
import android.view.LayoutInflater; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.widget.TextView; | |
public class Fragment_Setting extends Fragment { | |
private View cView; | |
private TextView title_text; | |
public Fragment_Setting() { | |
} | |
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { | |
if(this.cView == null) { | |
this.cView = inflater.inflate(2130903042, container, false); | |
} | |
this.init(); | |
return this.cView; | |
} | |
private void init() { | |
this.title_text = (TextView)this.cView.findViewById(2131034202); | |
this.title_text.setText("设置"); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.fragment; | |
import android.os.Bundle; | |
import android.support.v4.app.Fragment; | |
import android.view.LayoutInflater; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.widget.TextView; | |
public class Fragment_User extends Fragment { | |
private View cView; | |
private TextView title_text; | |
public Fragment_User() { | |
} | |
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { | |
if(this.cView == null) { | |
this.cView = inflater.inflate(2130903043, container, false); | |
} | |
this.init(); | |
return this.cView; | |
} | |
private void init() { | |
this.title_text = (TextView)this.cView.findViewById(2131034202); | |
this.title_text.setText("我的资料"); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public class HumanBean { | |
private String name; | |
private boolean choice; | |
public HumanBean() { | |
} | |
public String getName() { | |
return this.name; | |
} | |
public void setName(String name) { | |
this.name = name; | |
} | |
public boolean isChoice() { | |
return this.choice; | |
} | |
public void setChoice(boolean choice) { | |
this.choice = choice; | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
import android.app.Application; | |
import com.avos.avoscloud.AVOSCloud; | |
public class MyApplication extends Application { | |
public MyApplication() { | |
} | |
public void onCreate() { | |
super.onCreate(); | |
AVOSCloud.initialize(this, "4BR6Jm0KJL862m9uNhoOk2ef", "UAPDQhH71eCSjJdBm9JOkdV5"); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class R$anim { | |
public static final int popupwindow_enter = 2130968576; | |
public static final int popupwindow_exit = 2130968577; | |
public static final int search_popup_enter = 2130968578; | |
public static final int search_popup_exit = 2130968579; | |
public R$anim() { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class R$array { | |
public static final int search_pay_state = 2131296258; | |
public static final int search_who = 2131296257; | |
public static final int whopay = 2131296256; | |
public R$array() { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class R$attr { | |
public static final int borderRadius = 2130771968; | |
public static final int src = 2130771970; | |
public static final int type = 2130771969; | |
public R$attr() { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class R$color { | |
public static final int RadioButton_bg_no = 2131099648; | |
public static final int RadioButton_bg_sel = 2131099649; | |
public static final int my_sure_btn_sel = 2131099650; | |
public static final int popup_bg_color = 2131099651; | |
public static final int search_popup_btn_bg_no = 2131099652; | |
public R$color() { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class R$dimen { | |
public static final int activity_horizontal_margin = 2131165184; | |
public static final int activity_vertical_margin = 2131165185; | |
public R$dimen() { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class R$drawable { | |
public static final int a11 = 2130837504; | |
public static final int add_note_no = 2130837505; | |
public static final int add_note_sel = 2130837506; | |
public static final int back_no = 2130837507; | |
public static final int back_sel = 2130837508; | |
public static final int change_state = 2130837509; | |
public static final int dagou = 2130837510; | |
public static final int home = 2130837511; | |
public static final int ic_arrow_left = 2130837512; | |
public static final int ic_arrow_right = 2130837513; | |
public static final int ic_delete = 2130837514; | |
public static final int ic_launcher = 2130837515; | |
public static final int img_1 = 2130837516; | |
public static final int img_2 = 2130837517; | |
public static final int img_3 = 2130837518; | |
public static final int img_4 = 2130837519; | |
public static final int img_5 = 2130837520; | |
public static final int img_6 = 2130837521; | |
public static final int item_bg = 2130837522; | |
public static final int listview_div = 2130837523; | |
public static final int logo = 2130837524; | |
public static final int other_no = 2130837525; | |
public static final int other_sel = 2130837526; | |
public static final int record_no = 2130837527; | |
public static final int record_sel = 2130837528; | |
public static final int search_img = 2130837529; | |
public static final int search_no = 2130837530; | |
public static final int search_sel = 2130837531; | |
public static final int select_add_note_bg = 2130837532; | |
public static final int select_btn_sure = 2130837533; | |
public static final int selector_btn_menu_item_1 = 2130837534; | |
public static final int selector_btn_menu_item_2 = 2130837535; | |
public static final int selector_btn_menu_item_3 = 2130837536; | |
public static final int selector_popup_btn_cancle = 2130837537; | |
public static final int selector_popup_btn_sure_bg = 2130837538; | |
public static final int selector_search_pop_btn_bg = 2130837539; | |
public static final int selector_titlebar_back = 2130837540; | |
public static final int setting = 2130837541; | |
public static final int shape_popup_bg = 2130837542; | |
public static final int shape_popup_cancle_no = 2130837543; | |
public static final int shape_popup_cancle_sel = 2130837544; | |
public static final int shape_popup_sure_no = 2130837545; | |
public static final int shape_popup_sure_sel = 2130837546; | |
public static final int tx_no = 2130837547; | |
public static final int user = 2130837548; | |
public R$drawable() { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class R$id { | |
public static final int action_settings = 2131034210; | |
public static final int circle = 2131034112; | |
public static final int grid_item_img_choice = 2131034169; | |
public static final int grid_item_img_touxiang = 2131034167; | |
public static final int grid_item_text_name = 2131034168; | |
public static final int home_img = 2131034120; | |
public static final int home_menu_item_btn_1 = 2131034122; | |
public static final int home_menu_item_btn_2 = 2131034125; | |
public static final int home_menu_item_btn_3 = 2131034128; | |
public static final int home_menu_item_text_1 = 2131034123; | |
public static final int home_menu_item_text_2 = 2131034126; | |
public static final int home_menu_item_text_3 = 2131034129; | |
public static final int home_menu_row1_1 = 2131034121; | |
public static final int home_menu_row1_2 = 2131034124; | |
public static final int home_menu_row1_3 = 2131034127; | |
public static final int home_title = 2131034119; | |
public static final int imageView1 = 2131034187; | |
public static final int linearLayout1 = 2131034192; | |
public static final int list_foot_bar = 2131034166; | |
public static final int list_foot_text = 2131034165; | |
public static final int main_btn_add_note = 2131034161; | |
public static final int main_btn_sure = 2131034164; | |
public static final int main_date_text = 2131034154; | |
public static final int main_edit_money = 2131034157; | |
public static final int main_gridview = 2131034163; | |
public static final int main_le_date = 2131034153; | |
public static final int main_le_money = 2131034155; | |
public static final int main_le_whopay = 2131034158; | |
public static final int main_whopay_spinner = 2131034160; | |
public static final int main_whopay_text = 2131034159; | |
public static final int perinfo_le_1 = 2131034139; | |
public static final int perinfo_le_2 = 2131034143; | |
public static final int perinfo_listview = 2131034150; | |
public static final int perinfo_re_1 = 2131034138; | |
public static final int perinfo_spinner_name = 2131034140; | |
public static final int perinfo_spinner_paystate = 2131034141; | |
public static final int perinfo_text_allmoney = 2131034145; | |
public static final int perinfo_text_data = 2131034142; | |
public static final int perinfo_text_jiesuan_money = 2131034149; | |
public static final int perinfo_text_jiesuan_str = 2131034148; | |
public static final int perinfo_text_money_val = 2131034144; | |
public static final int perinfo_text_yufu_money = 2131034147; | |
public static final int perinfo_text_yufu_str = 2131034146; | |
public static final int perinfo_title = 2131034137; | |
public static final int pop_btn_cancle = 2131034190; | |
public static final int pop_btn_sure = 2131034191; | |
public static final int pop_edit_note = 2131034188; | |
public static final int pop_le_1 = 2131034189; | |
public static final int relativeLayout1 = 2131034170; | |
public static final int round = 2131034113; | |
public static final int search_all_btn = 2131034136; | |
public static final int search_all_item_date = 2131034193; | |
public static final int search_all_item_le_note = 2131034196; | |
public static final int search_all_item_money = 2131034194; | |
public static final int search_all_item_state = 2131034201; | |
public static final int search_all_item_text_note = 2131034198; | |
public static final int search_all_item_who = 2131034195; | |
public static final int search_all_item_whopay = 2131034200; | |
public static final int search_all_listview = 2131034135; | |
public static final int search_popup_all_linear = 2131034174; | |
public static final int search_popup_btn_cancel = 2131034172; | |
public static final int search_popup_btn_linear = 2131034171; | |
public static final int search_popup_btn_sure = 2131034173; | |
public static final int search_popup_linear_1 = 2131034175; | |
public static final int search_popup_linear_2 = 2131034180; | |
public static final int search_popup_linear_3 = 2131034183; | |
public static final int search_popup_text_date = 2131034177; | |
public static final int search_popup_text_money = 2131034179; | |
public static final int search_popup_text_who = 2131034182; | |
public static final int search_popup_text_yufu = 2131034185; | |
public static final int search_popup_wait_bar = 2131034186; | |
public static final int search_re = 2131034133; | |
public static final int serach_all_titlebar = 2131034134; | |
public static final int setting_title = 2131034130; | |
public static final int submit_main = 2131034151; | |
public static final int submit_title = 2131034152; | |
public static final int tab_home = 2131034115; | |
public static final int tab_setting = 2131034117; | |
public static final int tab_user = 2131034116; | |
public static final int textView1 = 2131034131; | |
public static final int textView2 = 2131034181; | |
public static final int textView3 = 2131034156; | |
public static final int textView4 = 2131034162; | |
public static final int textView5 = 2131034197; | |
public static final int textView7 = 2131034199; | |
public static final int textView_yufu = 2131034184; | |
public static final int text_jine = 2131034178; | |
public static final int text_str_date = 2131034176; | |
public static final int titlebar_back = 2131034203; | |
public static final int titlebar_title = 2131034202; | |
public static final int toast_text = 2131034132; | |
public static final int view_content = 2131034118; | |
public static final int view_tab = 2131034114; | |
public static final int widgetCalendar_calendar = 2131034209; | |
public static final int widgetCalendar_imgForeMonth = 2131034205; | |
public static final int widgetCalendar_imgForeYear = 2131034204; | |
public static final int widgetCalendar_imgNextMonth = 2131034207; | |
public static final int widgetCalendar_imgNextYear = 2131034208; | |
public static final int widgetCalendar_txtTitle = 2131034206; | |
public R$id() { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class R$layout { | |
public static final int activity_main = 2130903040; | |
public static final int fragment_layout_home = 2130903041; | |
public static final int fragment_layout_setting = 2130903042; | |
public static final int fragment_layout_user = 2130903043; | |
public static final int layout_logo = 2130903044; | |
public static final int layout_mytoast = 2130903045; | |
public static final int layout_search_all = 2130903046; | |
public static final int layout_search_perinfo = 2130903047; | |
public static final int layout_submitinfo = 2130903048; | |
public static final int listview_foot_layout = 2130903049; | |
public static final int main_grid_item = 2130903050; | |
public static final int popup_layout_jiesuan = 2130903051; | |
public static final int popupwindow = 2130903052; | |
public static final int search_all_item = 2130903053; | |
public static final int title_bar = 2130903054; | |
public static final int widget_calendar = 2130903055; | |
public R$layout() { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class R$string { | |
public static final int action_settings = 2131230721; | |
public static final int app_name = 2131230720; | |
public static final int hello_world = 2131230722; | |
public R$string() { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class R$style { | |
public static final int AppBaseTheme = 2131361792; | |
public static final int AppTheme = 2131361793; | |
public static final int popWindow_animation = 2131361795; | |
public static final int search_popWindow_animation = 2131361796; | |
public static final int tab_textview = 2131361794; | |
public R$style() { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class R$styleable { | |
public static final int[] RoundImageView = new int[]{2130771968, 2130771969}; | |
public static final int RoundImageView_borderRadius = 0; | |
public static final int RoundImageView_type = 1; | |
public R$styleable() { | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome; | |
public final class R { | |
public R() { | |
} | |
public static final class anim { | |
public static final int popupwindow_enter = 2130968576; | |
public static final int popupwindow_exit = 2130968577; | |
public static final int search_popup_enter = 2130968578; | |
public static final int search_popup_exit = 2130968579; | |
public anim() { | |
} | |
} | |
public static final class array { | |
public static final int search_pay_state = 2131296258; | |
public static final int search_who = 2131296257; | |
public static final int whopay = 2131296256; | |
public array() { | |
} | |
} | |
public static final class attr { | |
public static final int borderRadius = 2130771968; | |
public static final int src = 2130771970; | |
public static final int type = 2130771969; | |
public attr() { | |
} | |
} | |
public static final class color { | |
public static final int RadioButton_bg_no = 2131099648; | |
public static final int RadioButton_bg_sel = 2131099649; | |
public static final int my_sure_btn_sel = 2131099650; | |
public static final int popup_bg_color = 2131099651; | |
public static final int search_popup_btn_bg_no = 2131099652; | |
public color() { | |
} | |
} | |
public static final class dimen { | |
public static final int activity_horizontal_margin = 2131165184; | |
public static final int activity_vertical_margin = 2131165185; | |
public dimen() { | |
} | |
} | |
public static final class drawable { | |
public static final int a11 = 2130837504; | |
public static final int add_note_no = 2130837505; | |
public static final int add_note_sel = 2130837506; | |
public static final int back_no = 2130837507; | |
public static final int back_sel = 2130837508; | |
public static final int change_state = 2130837509; | |
public static final int dagou = 2130837510; | |
public static final int home = 2130837511; | |
public static final int ic_arrow_left = 2130837512; | |
public static final int ic_arrow_right = 2130837513; | |
public static final int ic_delete = 2130837514; | |
public static final int ic_launcher = 2130837515; | |
public static final int img_1 = 2130837516; | |
public static final int img_2 = 2130837517; | |
public static final int img_3 = 2130837518; | |
public static final int img_4 = 2130837519; | |
public static final int img_5 = 2130837520; | |
public static final int img_6 = 2130837521; | |
public static final int item_bg = 2130837522; | |
public static final int listview_div = 2130837523; | |
public static final int logo = 2130837524; | |
public static final int other_no = 2130837525; | |
public static final int other_sel = 2130837526; | |
public static final int record_no = 2130837527; | |
public static final int record_sel = 2130837528; | |
public static final int search_img = 2130837529; | |
public static final int search_no = 2130837530; | |
public static final int search_sel = 2130837531; | |
public static final int select_add_note_bg = 2130837532; | |
public static final int select_btn_sure = 2130837533; | |
public static final int selector_btn_menu_item_1 = 2130837534; | |
public static final int selector_btn_menu_item_2 = 2130837535; | |
public static final int selector_btn_menu_item_3 = 2130837536; | |
public static final int selector_popup_btn_cancle = 2130837537; | |
public static final int selector_popup_btn_sure_bg = 2130837538; | |
public static final int selector_search_pop_btn_bg = 2130837539; | |
public static final int selector_titlebar_back = 2130837540; | |
public static final int setting = 2130837541; | |
public static final int shape_popup_bg = 2130837542; | |
public static final int shape_popup_cancle_no = 2130837543; | |
public static final int shape_popup_cancle_sel = 2130837544; | |
public static final int shape_popup_sure_no = 2130837545; | |
public static final int shape_popup_sure_sel = 2130837546; | |
public static final int tx_no = 2130837547; | |
public static final int user = 2130837548; | |
public drawable() { | |
} | |
} | |
public static final class id { | |
public static final int action_settings = 2131034210; | |
public static final int circle = 2131034112; | |
public static final int grid_item_img_choice = 2131034169; | |
public static final int grid_item_img_touxiang = 2131034167; | |
public static final int grid_item_text_name = 2131034168; | |
public static final int home_img = 2131034120; | |
public static final int home_menu_item_btn_1 = 2131034122; | |
public static final int home_menu_item_btn_2 = 2131034125; | |
public static final int home_menu_item_btn_3 = 2131034128; | |
public static final int home_menu_item_text_1 = 2131034123; | |
public static final int home_menu_item_text_2 = 2131034126; | |
public static final int home_menu_item_text_3 = 2131034129; | |
public static final int home_menu_row1_1 = 2131034121; | |
public static final int home_menu_row1_2 = 2131034124; | |
public static final int home_menu_row1_3 = 2131034127; | |
public static final int home_title = 2131034119; | |
public static final int imageView1 = 2131034187; | |
public static final int linearLayout1 = 2131034192; | |
public static final int list_foot_bar = 2131034166; | |
public static final int list_foot_text = 2131034165; | |
public static final int main_btn_add_note = 2131034161; | |
public static final int main_btn_sure = 2131034164; | |
public static final int main_date_text = 2131034154; | |
public static final int main_edit_money = 2131034157; | |
public static final int main_gridview = 2131034163; | |
public static final int main_le_date = 2131034153; | |
public static final int main_le_money = 2131034155; | |
public static final int main_le_whopay = 2131034158; | |
public static final int main_whopay_spinner = 2131034160; | |
public static final int main_whopay_text = 2131034159; | |
public static final int perinfo_le_1 = 2131034139; | |
public static final int perinfo_le_2 = 2131034143; | |
public static final int perinfo_listview = 2131034150; | |
public static final int perinfo_re_1 = 2131034138; | |
public static final int perinfo_spinner_name = 2131034140; | |
public static final int perinfo_spinner_paystate = 2131034141; | |
public static final int perinfo_text_allmoney = 2131034145; | |
public static final int perinfo_text_data = 2131034142; | |
public static final int perinfo_text_jiesuan_money = 2131034149; | |
public static final int perinfo_text_jiesuan_str = 2131034148; | |
public static final int perinfo_text_money_val = 2131034144; | |
public static final int perinfo_text_yufu_money = 2131034147; | |
public static final int perinfo_text_yufu_str = 2131034146; | |
public static final int perinfo_title = 2131034137; | |
public static final int pop_btn_cancle = 2131034190; | |
public static final int pop_btn_sure = 2131034191; | |
public static final int pop_edit_note = 2131034188; | |
public static final int pop_le_1 = 2131034189; | |
public static final int relativeLayout1 = 2131034170; | |
public static final int round = 2131034113; | |
public static final int search_all_btn = 2131034136; | |
public static final int search_all_item_date = 2131034193; | |
public static final int search_all_item_le_note = 2131034196; | |
public static final int search_all_item_money = 2131034194; | |
public static final int search_all_item_state = 2131034201; | |
public static final int search_all_item_text_note = 2131034198; | |
public static final int search_all_item_who = 2131034195; | |
public static final int search_all_item_whopay = 2131034200; | |
public static final int search_all_listview = 2131034135; | |
public static final int search_popup_all_linear = 2131034174; | |
public static final int search_popup_btn_cancel = 2131034172; | |
public static final int search_popup_btn_linear = 2131034171; | |
public static final int search_popup_btn_sure = 2131034173; | |
public static final int search_popup_linear_1 = 2131034175; | |
public static final int search_popup_linear_2 = 2131034180; | |
public static final int search_popup_linear_3 = 2131034183; | |
public static final int search_popup_text_date = 2131034177; | |
public static final int search_popup_text_money = 2131034179; | |
public static final int search_popup_text_who = 2131034182; | |
public static final int search_popup_text_yufu = 2131034185; | |
public static final int search_popup_wait_bar = 2131034186; | |
public static final int search_re = 2131034133; | |
public static final int serach_all_titlebar = 2131034134; | |
public static final int setting_title = 2131034130; | |
public static final int submit_main = 2131034151; | |
public static final int submit_title = 2131034152; | |
public static final int tab_home = 2131034115; | |
public static final int tab_setting = 2131034117; | |
public static final int tab_user = 2131034116; | |
public static final int textView1 = 2131034131; | |
public static final int textView2 = 2131034181; | |
public static final int textView3 = 2131034156; | |
public static final int textView4 = 2131034162; | |
public static final int textView5 = 2131034197; | |
public static final int textView7 = 2131034199; | |
public static final int textView_yufu = 2131034184; | |
public static final int text_jine = 2131034178; | |
public static final int text_str_date = 2131034176; | |
public static final int titlebar_back = 2131034203; | |
public static final int titlebar_title = 2131034202; | |
public static final int toast_text = 2131034132; | |
public static final int view_content = 2131034118; | |
public static final int view_tab = 2131034114; | |
public static final int widgetCalendar_calendar = 2131034209; | |
public static final int widgetCalendar_imgForeMonth = 2131034205; | |
public static final int widgetCalendar_imgForeYear = 2131034204; | |
public static final int widgetCalendar_imgNextMonth = 2131034207; | |
public static final int widgetCalendar_imgNextYear = 2131034208; | |
public static final int widgetCalendar_txtTitle = 2131034206; | |
public id() { | |
} | |
} | |
public static final class layout { | |
public static final int activity_main = 2130903040; | |
public static final int fragment_layout_home = 2130903041; | |
public static final int fragment_layout_setting = 2130903042; | |
public static final int fragment_layout_user = 2130903043; | |
public static final int layout_logo = 2130903044; | |
public static final int layout_mytoast = 2130903045; | |
public static final int layout_search_all = 2130903046; | |
public static final int layout_search_perinfo = 2130903047; | |
public static final int layout_submitinfo = 2130903048; | |
public static final int listview_foot_layout = 2130903049; | |
public static final int main_grid_item = 2130903050; | |
public static final int popup_layout_jiesuan = 2130903051; | |
public static final int popupwindow = 2130903052; | |
public static final int search_all_item = 2130903053; | |
public static final int title_bar = 2130903054; | |
public static final int widget_calendar = 2130903055; | |
public layout() { | |
} | |
} | |
public static final class menu { | |
public static final int main = 2131427328; | |
public menu() { | |
} | |
} | |
public static final class string { | |
public static final int action_settings = 2131230721; | |
public static final int app_name = 2131230720; | |
public static final int hello_world = 2131230722; | |
public string() { | |
} | |
} | |
public static final class style { | |
public static final int AppBaseTheme = 2131361792; | |
public static final int AppTheme = 2131361793; | |
public static final int popWindow_animation = 2131361795; | |
public static final int search_popWindow_animation = 2131361796; | |
public static final int tab_textview = 2131361794; | |
public style() { | |
} | |
} | |
public static final class styleable { | |
public static final int[] RoundImageView = new int[]{2130771968, 2130771969}; | |
public static final int RoundImageView_borderRadius = 0; | |
public static final int RoundImageView_type = 1; | |
public styleable() { | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.utils; | |
import com.mysoft.myhome.utils.ACache.ACacheManager; | |
import java.io.File; | |
class ACache$ACacheManager$1 implements Runnable { | |
ACache$ACacheManager$1(ACacheManager var1) { | |
this.this$1 = var1; | |
} | |
public void run() { | |
int size = 0; | |
int count = 0; | |
File[] cachedFiles = this.this$1.cacheDir.listFiles(); | |
if(cachedFiles != null) { | |
File[] var7 = cachedFiles; | |
int var6 = cachedFiles.length; | |
for(int var5 = 0; var5 < var6; ++var5) { | |
File cachedFile = var7[var5]; | |
size = (int)((long)size + ACacheManager.access$1(this.this$1, cachedFile)); | |
++count; | |
ACacheManager.access$2(this.this$1).put(cachedFile, Long.valueOf(cachedFile.lastModified())); | |
} | |
ACacheManager.access$3(this.this$1).set((long)size); | |
ACacheManager.access$4(this.this$1).set(count); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.utils; | |
import com.mysoft.myhome.utils.ACache; | |
import java.io.File; | |
import java.util.Collections; | |
import java.util.HashMap; | |
import java.util.Iterator; | |
import java.util.Map; | |
import java.util.Set; | |
import java.util.Map.Entry; | |
import java.util.concurrent.atomic.AtomicInteger; | |
import java.util.concurrent.atomic.AtomicLong; | |
public class ACache$ACacheManager { | |
private final AtomicLong cacheSize; | |
private final AtomicInteger cacheCount; | |
private final long sizeLimit; | |
private final int countLimit; | |
private final Map<File, Long> lastUsageDates; | |
protected File cacheDir; | |
private ACache$ACacheManager(ACache var1, File cacheDir, long sizeLimit, int countLimit) { | |
this.this$0 = var1; | |
this.lastUsageDates = Collections.synchronizedMap(new HashMap()); | |
this.cacheDir = cacheDir; | |
this.sizeLimit = sizeLimit; | |
this.countLimit = countLimit; | |
this.cacheSize = new AtomicLong(); | |
this.cacheCount = new AtomicInteger(); | |
this.calculateCacheSizeAndCacheCount(); | |
} | |
private void calculateCacheSizeAndCacheCount() { | |
(new Thread(new Runnable() { | |
public void run() { | |
int size = 0; | |
int count = 0; | |
File[] cachedFiles = ACache$ACacheManager.this.cacheDir.listFiles(); | |
if(cachedFiles != null) { | |
File[] var7 = cachedFiles; | |
int var6 = cachedFiles.length; | |
for(int var5 = 0; var5 < var6; ++var5) { | |
File cachedFile = var7[var5]; | |
size = (int)((long)size + ACache$ACacheManager.this.calculateSize(cachedFile)); | |
++count; | |
ACache$ACacheManager.this.lastUsageDates.put(cachedFile, Long.valueOf(cachedFile.lastModified())); | |
} | |
ACache$ACacheManager.this.cacheSize.set((long)size); | |
ACache$ACacheManager.this.cacheCount.set(count); | |
} | |
} | |
})).start(); | |
} | |
private void put(File file) { | |
long valueSize; | |
for(int curCacheCount = this.cacheCount.get(); curCacheCount + 1 > this.countLimit; curCacheCount = this.cacheCount.addAndGet(-1)) { | |
valueSize = this.removeNext(); | |
this.cacheSize.addAndGet(-valueSize); | |
} | |
this.cacheCount.addAndGet(1); | |
valueSize = this.calculateSize(file); | |
long currentTime; | |
for(long curCacheSize = this.cacheSize.get(); curCacheSize + valueSize > this.sizeLimit; curCacheSize = this.cacheSize.addAndGet(-currentTime)) { | |
currentTime = this.removeNext(); | |
} | |
this.cacheSize.addAndGet(valueSize); | |
Long currentTime1 = Long.valueOf(System.currentTimeMillis()); | |
file.setLastModified(currentTime1.longValue()); | |
this.lastUsageDates.put(file, currentTime1); | |
} | |
private File get(String key) { | |
File file = this.newFile(key); | |
Long currentTime = Long.valueOf(System.currentTimeMillis()); | |
file.setLastModified(currentTime.longValue()); | |
this.lastUsageDates.put(file, currentTime); | |
return file; | |
} | |
private File newFile(String key) { | |
return new File(this.cacheDir, String.valueOf(key.hashCode())); | |
} | |
private boolean remove(String key) { | |
File image = this.get(key); | |
return image.delete(); | |
} | |
private void clear() { | |
this.lastUsageDates.clear(); | |
this.cacheSize.set(0L); | |
File[] files = this.cacheDir.listFiles(); | |
if(files != null) { | |
File[] var5 = files; | |
int var4 = files.length; | |
for(int var3 = 0; var3 < var4; ++var3) { | |
File f = var5[var3]; | |
f.delete(); | |
} | |
} | |
} | |
private long removeNext() { | |
if(this.lastUsageDates.isEmpty()) { | |
return 0L; | |
} else { | |
Long oldestUsage = null; | |
File mostLongUsedFile = null; | |
Set entries = this.lastUsageDates.entrySet(); | |
Map fileSize = this.lastUsageDates; | |
synchronized(this.lastUsageDates) { | |
Iterator var6 = entries.iterator(); | |
while(true) { | |
if(!var6.hasNext()) { | |
break; | |
} | |
Entry entry = (Entry)var6.next(); | |
if(mostLongUsedFile == null) { | |
mostLongUsedFile = (File)entry.getKey(); | |
oldestUsage = (Long)entry.getValue(); | |
} else { | |
Long lastValueUsage = (Long)entry.getValue(); | |
if(lastValueUsage.longValue() < oldestUsage.longValue()) { | |
oldestUsage = lastValueUsage; | |
mostLongUsedFile = (File)entry.getKey(); | |
} | |
} | |
} | |
} | |
long fileSize1 = this.calculateSize(mostLongUsedFile); | |
if(mostLongUsedFile.delete()) { | |
this.lastUsageDates.remove(mostLongUsedFile); | |
} | |
return fileSize1; | |
} | |
} | |
private long calculateSize(File file) { | |
return file.length(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.utils; | |
import android.graphics.Bitmap; | |
import android.graphics.BitmapFactory; | |
import android.graphics.Canvas; | |
import android.graphics.Bitmap.CompressFormat; | |
import android.graphics.Bitmap.Config; | |
import android.graphics.drawable.BitmapDrawable; | |
import android.graphics.drawable.Drawable; | |
import java.io.ByteArrayOutputStream; | |
class ACache$Utils { | |
private static final char mSeparator = ' '; | |
private ACache$Utils() { | |
} | |
private static boolean isDue(String str) { | |
return isDue(str.getBytes()); | |
} | |
private static boolean isDue(byte[] data) { | |
String[] strs = getDateInfoFromDate(data); | |
if(strs != null && strs.length == 2) { | |
String saveTimeStr; | |
for(saveTimeStr = strs[0]; saveTimeStr.startsWith("0"); saveTimeStr = saveTimeStr.substring(1, saveTimeStr.length())) { | |
; | |
} | |
long saveTime = Long.valueOf(saveTimeStr).longValue(); | |
long deleteAfter = Long.valueOf(strs[1]).longValue(); | |
if(System.currentTimeMillis() > saveTime + deleteAfter * 1000L) { | |
return true; | |
} | |
} | |
return false; | |
} | |
private static String newStringWithDateInfo(int second, String strInfo) { | |
return createDateInfo(second) + strInfo; | |
} | |
private static byte[] newByteArrayWithDateInfo(int second, byte[] data2) { | |
byte[] data1 = createDateInfo(second).getBytes(); | |
byte[] retdata = new byte[data1.length + data2.length]; | |
System.arraycopy(data1, 0, retdata, 0, data1.length); | |
System.arraycopy(data2, 0, retdata, data1.length, data2.length); | |
return retdata; | |
} | |
private static String clearDateInfo(String strInfo) { | |
if(strInfo != null && hasDateInfo(strInfo.getBytes())) { | |
strInfo = strInfo.substring(strInfo.indexOf(32) + 1, strInfo.length()); | |
} | |
return strInfo; | |
} | |
private static byte[] clearDateInfo(byte[] data) { | |
return hasDateInfo(data)?copyOfRange(data, indexOf(data, ' ') + 1, data.length):data; | |
} | |
private static boolean hasDateInfo(byte[] data) { | |
return data != null && data.length > 15 && data[13] == 45 && indexOf(data, ' ') > 14; | |
} | |
private static String[] getDateInfoFromDate(byte[] data) { | |
if(hasDateInfo(data)) { | |
String saveDate = new String(copyOfRange(data, 0, 13)); | |
String deleteAfter = new String(copyOfRange(data, 14, indexOf(data, ' '))); | |
return new String[]{saveDate, deleteAfter}; | |
} else { | |
return null; | |
} | |
} | |
private static int indexOf(byte[] data, char c) { | |
for(int i = 0; i < data.length; ++i) { | |
if(data[i] == c) { | |
return i; | |
} | |
} | |
return -1; | |
} | |
private static byte[] copyOfRange(byte[] original, int from, int to) { | |
int newLength = to - from; | |
if(newLength < 0) { | |
throw new IllegalArgumentException(from + " > " + to); | |
} else { | |
byte[] copy = new byte[newLength]; | |
System.arraycopy(original, from, copy, 0, Math.min(original.length - from, newLength)); | |
return copy; | |
} | |
} | |
private static String createDateInfo(int second) { | |
String currentTime; | |
for(currentTime = String.valueOf(System.currentTimeMillis()); currentTime.length() < 13; currentTime = "0" + currentTime) { | |
; | |
} | |
return currentTime + "-" + second + ' '; | |
} | |
private static byte[] Bitmap2Bytes(Bitmap bm) { | |
if(bm == null) { | |
return null; | |
} else { | |
ByteArrayOutputStream baos = new ByteArrayOutputStream(); | |
bm.compress(CompressFormat.PNG, 100, baos); | |
return baos.toByteArray(); | |
} | |
} | |
private static Bitmap Bytes2Bimap(byte[] b) { | |
return b.length == 0?null:BitmapFactory.decodeByteArray(b, 0, b.length); | |
} | |
private static Bitmap drawable2Bitmap(Drawable drawable) { | |
if(drawable == null) { | |
return null; | |
} else { | |
int w = drawable.getIntrinsicWidth(); | |
int h = drawable.getIntrinsicHeight(); | |
Config config = drawable.getOpacity() != -1?Config.ARGB_8888:Config.RGB_565; | |
Bitmap bitmap = Bitmap.createBitmap(w, h, config); | |
Canvas canvas = new Canvas(bitmap); | |
drawable.setBounds(0, 0, w, h); | |
drawable.draw(canvas); | |
return bitmap; | |
} | |
} | |
private static Drawable bitmap2Drawable(Bitmap bm) { | |
if(bm == null) { | |
return null; | |
} else { | |
BitmapDrawable bd = new BitmapDrawable(bm); | |
bd.setTargetDensity(bm.getDensity()); | |
return new BitmapDrawable(bm); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.utils; | |
import com.mysoft.myhome.utils.ACache; | |
import com.mysoft.myhome.utils.ACache.ACacheManager; | |
import java.io.File; | |
import java.io.FileNotFoundException; | |
import java.io.FileOutputStream; | |
import java.io.IOException; | |
class ACache$xFileOutputStream extends FileOutputStream { | |
File file; | |
public ACache$xFileOutputStream(ACache var1, File file) throws FileNotFoundException { | |
super(file); | |
this.this$0 = var1; | |
this.file = file; | |
} | |
public void close() throws IOException { | |
super.close(); | |
ACacheManager.access$0(ACache.access$0(this.this$0), this.file); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.utils; | |
import android.content.Context; | |
import android.graphics.Bitmap; | |
import android.graphics.BitmapFactory; | |
import android.graphics.Canvas; | |
import android.graphics.Bitmap.CompressFormat; | |
import android.graphics.Bitmap.Config; | |
import android.graphics.drawable.BitmapDrawable; | |
import android.graphics.drawable.Drawable; | |
import android.os.Process; | |
import java.io.BufferedReader; | |
import java.io.BufferedWriter; | |
import java.io.ByteArrayInputStream; | |
import java.io.ByteArrayOutputStream; | |
import java.io.File; | |
import java.io.FileInputStream; | |
import java.io.FileNotFoundException; | |
import java.io.FileOutputStream; | |
import java.io.FileReader; | |
import java.io.FileWriter; | |
import java.io.IOException; | |
import java.io.InputStream; | |
import java.io.ObjectInputStream; | |
import java.io.ObjectOutputStream; | |
import java.io.OutputStream; | |
import java.io.RandomAccessFile; | |
import java.io.Serializable; | |
import java.util.Collections; | |
import java.util.HashMap; | |
import java.util.Iterator; | |
import java.util.Map; | |
import java.util.Set; | |
import java.util.Map.Entry; | |
import java.util.concurrent.atomic.AtomicInteger; | |
import java.util.concurrent.atomic.AtomicLong; | |
import org.json.JSONArray; | |
import org.json.JSONObject; | |
public class ACache { | |
public static final int TIME_HOUR = 3600; | |
public static final int TIME_DAY = 86400; | |
private static final int MAX_SIZE = 50000000; | |
private static final int MAX_COUNT = 2147483647; | |
private static Map<String, ACache> mInstanceMap = new HashMap(); | |
private ACache.ACacheManager mCache; | |
public static ACache get(Context ctx) { | |
return get(ctx, "ACache"); | |
} | |
public static ACache get(Context ctx, String cacheName) { | |
File f = new File(ctx.getCacheDir(), cacheName); | |
return get(f, 50000000L, 2147483647); | |
} | |
public static ACache get(File cacheDir) { | |
return get(cacheDir, 50000000L, 2147483647); | |
} | |
public static ACache get(Context ctx, long max_zise, int max_count) { | |
File f = new File(ctx.getCacheDir(), "ACache"); | |
return get(f, max_zise, max_count); | |
} | |
public static ACache get(File cacheDir, long max_zise, int max_count) { | |
ACache manager = (ACache)mInstanceMap.get(cacheDir.getAbsoluteFile() + myPid()); | |
if(manager == null) { | |
manager = new ACache(cacheDir, max_zise, max_count); | |
mInstanceMap.put(cacheDir.getAbsolutePath() + myPid(), manager); | |
} | |
return manager; | |
} | |
private static String myPid() { | |
return "_" + Process.myPid(); | |
} | |
private ACache(File cacheDir, long max_size, int max_count) { | |
if(!cacheDir.exists() && !cacheDir.mkdirs()) { | |
throw new RuntimeException("can\'t make dirs in " + cacheDir.getAbsolutePath()); | |
} else { | |
this.mCache = new ACache.ACacheManager(cacheDir, max_size, max_count, (ACache.ACacheManager)null); | |
} | |
} | |
public void put(String key, String value) { | |
File file = this.mCache.newFile(key); | |
BufferedWriter out = null; | |
try { | |
out = new BufferedWriter(new FileWriter(file), 1024); | |
out.write(value); | |
} catch (IOException var14) { | |
var14.printStackTrace(); | |
} finally { | |
if(out != null) { | |
try { | |
out.flush(); | |
out.close(); | |
} catch (IOException var13) { | |
var13.printStackTrace(); | |
} | |
} | |
this.mCache.put(file); | |
} | |
} | |
public void put(String key, String value, int saveTime) { | |
this.put(key, ACache.Utils.newStringWithDateInfo(saveTime, value)); | |
} | |
public String getAsString(String key) { | |
File file = this.mCache.get(key); | |
if(!file.exists()) { | |
return null; | |
} else { | |
boolean removeFile = false; | |
BufferedReader in = null; | |
try { | |
in = new BufferedReader(new FileReader(file)); | |
String e; | |
String currentLine; | |
for(e = ""; (currentLine = in.readLine()) != null; e = e + currentLine) { | |
; | |
} | |
if(!ACache.Utils.isDue(e)) { | |
String var8 = ACache.Utils.clearDateInfo(e); | |
return var8; | |
} | |
removeFile = true; | |
} catch (IOException var17) { | |
var17.printStackTrace(); | |
return null; | |
} finally { | |
if(in != null) { | |
try { | |
in.close(); | |
} catch (IOException var16) { | |
var16.printStackTrace(); | |
} | |
} | |
if(removeFile) { | |
this.remove(key); | |
} | |
} | |
return null; | |
} | |
} | |
public void put(String key, JSONObject value) { | |
this.put(key, value.toString()); | |
} | |
public void put(String key, JSONObject value, int saveTime) { | |
this.put(key, value.toString(), saveTime); | |
} | |
public JSONObject getAsJSONObject(String key) { | |
String JSONString = this.getAsString(key); | |
try { | |
JSONObject e = new JSONObject(JSONString); | |
return e; | |
} catch (Exception var4) { | |
var4.printStackTrace(); | |
return null; | |
} | |
} | |
public void put(String key, JSONArray value) { | |
this.put(key, value.toString()); | |
} | |
public void put(String key, JSONArray value, int saveTime) { | |
this.put(key, value.toString(), saveTime); | |
} | |
public JSONArray getAsJSONArray(String key) { | |
String JSONString = this.getAsString(key); | |
try { | |
JSONArray e = new JSONArray(JSONString); | |
return e; | |
} catch (Exception var4) { | |
var4.printStackTrace(); | |
return null; | |
} | |
} | |
public void put(String key, byte[] value) { | |
File file = this.mCache.newFile(key); | |
FileOutputStream out = null; | |
try { | |
out = new FileOutputStream(file); | |
out.write(value); | |
} catch (Exception var14) { | |
var14.printStackTrace(); | |
} finally { | |
if(out != null) { | |
try { | |
out.flush(); | |
out.close(); | |
} catch (IOException var13) { | |
var13.printStackTrace(); | |
} | |
} | |
this.mCache.put(file); | |
} | |
} | |
public OutputStream put(String key) throws FileNotFoundException { | |
return new ACache.xFileOutputStream(this.mCache.newFile(key)); | |
} | |
public InputStream get(String key) throws FileNotFoundException { | |
File file = this.mCache.get(key); | |
return !file.exists()?null:new FileInputStream(file); | |
} | |
public void put(String key, byte[] value, int saveTime) { | |
this.put(key, ACache.Utils.newByteArrayWithDateInfo(saveTime, value)); | |
} | |
public byte[] getAsBinary(String key) { | |
RandomAccessFile RAFile = null; | |
boolean removeFile = false; | |
try { | |
File e = this.mCache.get(key); | |
if(e.exists()) { | |
RAFile = new RandomAccessFile(e, "r"); | |
byte[] byteArray = new byte[(int)RAFile.length()]; | |
RAFile.read(byteArray); | |
if(!ACache.Utils.isDue(byteArray)) { | |
byte[] var7 = ACache.Utils.clearDateInfo(byteArray); | |
return var7; | |
} | |
removeFile = true; | |
return null; | |
} | |
return null; | |
} catch (Exception var17) { | |
var17.printStackTrace(); | |
} finally { | |
if(RAFile != null) { | |
try { | |
RAFile.close(); | |
} catch (IOException var16) { | |
var16.printStackTrace(); | |
} | |
} | |
if(removeFile) { | |
this.remove(key); | |
} | |
} | |
return null; | |
} | |
public void put(String key, Serializable value) { | |
this.put(key, (Serializable)value, -1); | |
} | |
public void put(String key, Serializable value, int saveTime) { | |
ByteArrayOutputStream baos = null; | |
ObjectOutputStream oos = null; | |
try { | |
baos = new ByteArrayOutputStream(); | |
oos = new ObjectOutputStream(baos); | |
oos.writeObject(value); | |
byte[] e = baos.toByteArray(); | |
if(saveTime != -1) { | |
this.put(key, e, saveTime); | |
} else { | |
this.put(key, e); | |
} | |
} catch (Exception var15) { | |
var15.printStackTrace(); | |
} finally { | |
try { | |
oos.close(); | |
} catch (IOException var14) { | |
; | |
} | |
} | |
} | |
public Object getAsObject(String key) { | |
byte[] data = this.getAsBinary(key); | |
if(data != null) { | |
ByteArrayInputStream bais = null; | |
ObjectInputStream ois = null; | |
try { | |
bais = new ByteArrayInputStream(data); | |
ois = new ObjectInputStream(bais); | |
Object e = ois.readObject(); | |
Object var7 = e; | |
return var7; | |
} catch (Exception var19) { | |
var19.printStackTrace(); | |
} finally { | |
try { | |
if(bais != null) { | |
bais.close(); | |
} | |
} catch (IOException var18) { | |
var18.printStackTrace(); | |
} | |
try { | |
if(ois != null) { | |
ois.close(); | |
} | |
} catch (IOException var17) { | |
var17.printStackTrace(); | |
} | |
} | |
return null; | |
} else { | |
return null; | |
} | |
} | |
public void put(String key, Bitmap value) { | |
this.put(key, ACache.Utils.Bitmap2Bytes(value)); | |
} | |
public void put(String key, Bitmap value, int saveTime) { | |
this.put(key, ACache.Utils.Bitmap2Bytes(value), saveTime); | |
} | |
public Bitmap getAsBitmap(String key) { | |
return this.getAsBinary(key) == null?null:ACache.Utils.Bytes2Bimap(this.getAsBinary(key)); | |
} | |
public void put(String key, Drawable value) { | |
this.put(key, ACache.Utils.drawable2Bitmap(value)); | |
} | |
public void put(String key, Drawable value, int saveTime) { | |
this.put(key, ACache.Utils.drawable2Bitmap(value), saveTime); | |
} | |
public Drawable getAsDrawable(String key) { | |
return this.getAsBinary(key) == null?null:ACache.Utils.bitmap2Drawable(ACache.Utils.Bytes2Bimap(this.getAsBinary(key))); | |
} | |
public File file(String key) { | |
File f = this.mCache.newFile(key); | |
return f.exists()?f:null; | |
} | |
public boolean remove(String key) { | |
return this.mCache.remove(key); | |
} | |
public void clear() { | |
this.mCache.clear(); | |
} | |
public class ACacheManager { | |
private final AtomicLong cacheSize; | |
private final AtomicInteger cacheCount; | |
private final long sizeLimit; | |
private final int countLimit; | |
private final Map<File, Long> lastUsageDates; | |
protected File cacheDir; | |
private ACacheManager(File cacheDir, long sizeLimit, int countLimit) { | |
this.lastUsageDates = Collections.synchronizedMap(new HashMap()); | |
this.cacheDir = cacheDir; | |
this.sizeLimit = sizeLimit; | |
this.countLimit = countLimit; | |
this.cacheSize = new AtomicLong(); | |
this.cacheCount = new AtomicInteger(); | |
this.calculateCacheSizeAndCacheCount(); | |
} | |
private void calculateCacheSizeAndCacheCount() { | |
(new Thread(new Runnable() { | |
public void run() { | |
int size = 0; | |
int count = 0; | |
File[] cachedFiles = ACacheManager.this.cacheDir.listFiles(); | |
if(cachedFiles != null) { | |
File[] var7 = cachedFiles; | |
int var6 = cachedFiles.length; | |
for(int var5 = 0; var5 < var6; ++var5) { | |
File cachedFile = var7[var5]; | |
size = (int)((long)size + ACacheManager.this.calculateSize(cachedFile)); | |
++count; | |
ACacheManager.this.lastUsageDates.put(cachedFile, Long.valueOf(cachedFile.lastModified())); | |
} | |
ACacheManager.this.cacheSize.set((long)size); | |
ACacheManager.this.cacheCount.set(count); | |
} | |
} | |
})).start(); | |
} | |
private void put(File file) { | |
long valueSize; | |
for(int curCacheCount = this.cacheCount.get(); curCacheCount + 1 > this.countLimit; curCacheCount = this.cacheCount.addAndGet(-1)) { | |
valueSize = this.removeNext(); | |
this.cacheSize.addAndGet(-valueSize); | |
} | |
this.cacheCount.addAndGet(1); | |
valueSize = this.calculateSize(file); | |
long currentTime; | |
for(long curCacheSize = this.cacheSize.get(); curCacheSize + valueSize > this.sizeLimit; curCacheSize = this.cacheSize.addAndGet(-currentTime)) { | |
currentTime = this.removeNext(); | |
} | |
this.cacheSize.addAndGet(valueSize); | |
Long currentTime1 = Long.valueOf(System.currentTimeMillis()); | |
file.setLastModified(currentTime1.longValue()); | |
this.lastUsageDates.put(file, currentTime1); | |
} | |
private File get(String key) { | |
File file = this.newFile(key); | |
Long currentTime = Long.valueOf(System.currentTimeMillis()); | |
file.setLastModified(currentTime.longValue()); | |
this.lastUsageDates.put(file, currentTime); | |
return file; | |
} | |
private File newFile(String key) { | |
return new File(this.cacheDir, String.valueOf(key.hashCode())); | |
} | |
private boolean remove(String key) { | |
File image = this.get(key); | |
return image.delete(); | |
} | |
private void clear() { | |
this.lastUsageDates.clear(); | |
this.cacheSize.set(0L); | |
File[] files = this.cacheDir.listFiles(); | |
if(files != null) { | |
File[] var5 = files; | |
int var4 = files.length; | |
for(int var3 = 0; var3 < var4; ++var3) { | |
File f = var5[var3]; | |
f.delete(); | |
} | |
} | |
} | |
private long removeNext() { | |
if(this.lastUsageDates.isEmpty()) { | |
return 0L; | |
} else { | |
Long oldestUsage = null; | |
File mostLongUsedFile = null; | |
Set entries = this.lastUsageDates.entrySet(); | |
Map fileSize = this.lastUsageDates; | |
synchronized(this.lastUsageDates) { | |
Iterator var6 = entries.iterator(); | |
while(true) { | |
if(!var6.hasNext()) { | |
break; | |
} | |
Entry entry = (Entry)var6.next(); | |
if(mostLongUsedFile == null) { | |
mostLongUsedFile = (File)entry.getKey(); | |
oldestUsage = (Long)entry.getValue(); | |
} else { | |
Long lastValueUsage = (Long)entry.getValue(); | |
if(lastValueUsage.longValue() < oldestUsage.longValue()) { | |
oldestUsage = lastValueUsage; | |
mostLongUsedFile = (File)entry.getKey(); | |
} | |
} | |
} | |
} | |
long fileSize1 = this.calculateSize(mostLongUsedFile); | |
if(mostLongUsedFile.delete()) { | |
this.lastUsageDates.remove(mostLongUsedFile); | |
} | |
return fileSize1; | |
} | |
} | |
private long calculateSize(File file) { | |
return file.length(); | |
} | |
} | |
private static class Utils { | |
private static final char mSeparator = ' '; | |
private Utils() { | |
} | |
private static boolean isDue(String str) { | |
return isDue(str.getBytes()); | |
} | |
private static boolean isDue(byte[] data) { | |
String[] strs = getDateInfoFromDate(data); | |
if(strs != null && strs.length == 2) { | |
String saveTimeStr; | |
for(saveTimeStr = strs[0]; saveTimeStr.startsWith("0"); saveTimeStr = saveTimeStr.substring(1, saveTimeStr.length())) { | |
; | |
} | |
long saveTime = Long.valueOf(saveTimeStr).longValue(); | |
long deleteAfter = Long.valueOf(strs[1]).longValue(); | |
if(System.currentTimeMillis() > saveTime + deleteAfter * 1000L) { | |
return true; | |
} | |
} | |
return false; | |
} | |
private static String newStringWithDateInfo(int second, String strInfo) { | |
return createDateInfo(second) + strInfo; | |
} | |
private static byte[] newByteArrayWithDateInfo(int second, byte[] data2) { | |
byte[] data1 = createDateInfo(second).getBytes(); | |
byte[] retdata = new byte[data1.length + data2.length]; | |
System.arraycopy(data1, 0, retdata, 0, data1.length); | |
System.arraycopy(data2, 0, retdata, data1.length, data2.length); | |
return retdata; | |
} | |
private static String clearDateInfo(String strInfo) { | |
if(strInfo != null && hasDateInfo(strInfo.getBytes())) { | |
strInfo = strInfo.substring(strInfo.indexOf(32) + 1, strInfo.length()); | |
} | |
return strInfo; | |
} | |
private static byte[] clearDateInfo(byte[] data) { | |
return hasDateInfo(data)?copyOfRange(data, indexOf(data, ' ') + 1, data.length):data; | |
} | |
private static boolean hasDateInfo(byte[] data) { | |
return data != null && data.length > 15 && data[13] == 45 && indexOf(data, ' ') > 14; | |
} | |
private static String[] getDateInfoFromDate(byte[] data) { | |
if(hasDateInfo(data)) { | |
String saveDate = new String(copyOfRange(data, 0, 13)); | |
String deleteAfter = new String(copyOfRange(data, 14, indexOf(data, ' '))); | |
return new String[]{saveDate, deleteAfter}; | |
} else { | |
return null; | |
} | |
} | |
private static int indexOf(byte[] data, char c) { | |
for(int i = 0; i < data.length; ++i) { | |
if(data[i] == c) { | |
return i; | |
} | |
} | |
return -1; | |
} | |
private static byte[] copyOfRange(byte[] original, int from, int to) { | |
int newLength = to - from; | |
if(newLength < 0) { | |
throw new IllegalArgumentException(from + " > " + to); | |
} else { | |
byte[] copy = new byte[newLength]; | |
System.arraycopy(original, from, copy, 0, Math.min(original.length - from, newLength)); | |
return copy; | |
} | |
} | |
private static String createDateInfo(int second) { | |
String currentTime; | |
for(currentTime = String.valueOf(System.currentTimeMillis()); currentTime.length() < 13; currentTime = "0" + currentTime) { | |
; | |
} | |
return currentTime + "-" + second + ' '; | |
} | |
private static byte[] Bitmap2Bytes(Bitmap bm) { | |
if(bm == null) { | |
return null; | |
} else { | |
ByteArrayOutputStream baos = new ByteArrayOutputStream(); | |
bm.compress(CompressFormat.PNG, 100, baos); | |
return baos.toByteArray(); | |
} | |
} | |
private static Bitmap Bytes2Bimap(byte[] b) { | |
return b.length == 0?null:BitmapFactory.decodeByteArray(b, 0, b.length); | |
} | |
private static Bitmap drawable2Bitmap(Drawable drawable) { | |
if(drawable == null) { | |
return null; | |
} else { | |
int w = drawable.getIntrinsicWidth(); | |
int h = drawable.getIntrinsicHeight(); | |
Config config = drawable.getOpacity() != -1?Config.ARGB_8888:Config.RGB_565; | |
Bitmap bitmap = Bitmap.createBitmap(w, h, config); | |
Canvas canvas = new Canvas(bitmap); | |
drawable.setBounds(0, 0, w, h); | |
drawable.draw(canvas); | |
return bitmap; | |
} | |
} | |
private static Drawable bitmap2Drawable(Bitmap bm) { | |
if(bm == null) { | |
return null; | |
} else { | |
BitmapDrawable bd = new BitmapDrawable(bm); | |
bd.setTargetDensity(bm.getDensity()); | |
return new BitmapDrawable(bm); | |
} | |
} | |
} | |
class xFileOutputStream extends FileOutputStream { | |
File file; | |
public xFileOutputStream(File file) throws FileNotFoundException { | |
super(file); | |
this.file = file; | |
} | |
public void close() throws IOException { | |
super.close(); | |
ACache.this.mCache.put(this.file); | |
} | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.utils; | |
import android.content.Context; | |
import android.widget.Toast; | |
public class AllUtils { | |
static Toast toast; | |
public AllUtils() { | |
} | |
public static void showToast(Context context, String str) { | |
if(toast == null) { | |
toast = Toast.makeText(context, str, 0); | |
} | |
toast.setText(str); | |
toast.show(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.utils; | |
import android.content.Context; | |
import android.widget.Toast; | |
import java.text.SimpleDateFormat; | |
import java.util.Date; | |
public class MainUtils { | |
Context context; | |
Toast toast; | |
public MainUtils(Context context) { | |
this.context = context; | |
} | |
public String getDate() { | |
Long time = Long.valueOf(System.currentTimeMillis()); | |
Date date = new Date(time.longValue()); | |
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd"); | |
String str_time = dateFormat.format(date); | |
return str_time; | |
} | |
public void showToast(String str) { | |
if(this.toast == null) { | |
this.toast = Toast.makeText(this.context, str, 0); | |
} | |
this.toast.setText(str); | |
this.toast.show(); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.utils; | |
import android.content.Context; | |
import android.content.SharedPreferences; | |
import android.content.SharedPreferences.Editor; | |
import java.util.HashSet; | |
import java.util.Set; | |
public class MyPreferences { | |
SharedPreferences preferences = null; | |
Editor editor = null; | |
public MyPreferences(Context context) { | |
this.preferences = context.getSharedPreferences("Settings", 0); | |
this.editor = this.preferences.edit(); | |
} | |
public String getString(String key) { | |
return this.preferences.getString(key, "Nothing"); | |
} | |
public void setString(String key, String str) { | |
this.editor.putString(key, str); | |
this.editor.commit(); | |
} | |
public void setList(String key, Set<String> values) { | |
this.editor.putStringSet(key, values); | |
this.editor.commit(); | |
} | |
public Set<String> getList(String key) { | |
HashSet siteno = new HashSet(); | |
return this.preferences.getStringSet(key, siteno); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.view; | |
import android.content.Context; | |
import android.graphics.Bitmap; | |
import android.graphics.BitmapShader; | |
import android.graphics.Canvas; | |
import android.graphics.Matrix; | |
import android.graphics.Paint; | |
import android.graphics.Bitmap.Config; | |
import android.graphics.Shader.TileMode; | |
import android.graphics.drawable.BitmapDrawable; | |
import android.graphics.drawable.Drawable; | |
import android.util.AttributeSet; | |
import android.widget.ImageView; | |
public class RotateImage extends ImageView { | |
private Bitmap mBitmap; | |
private Paint mPaint; | |
private Matrix mMatrix; | |
private int mWidth; | |
private int mHeight; | |
private int mRadius; | |
private BitmapShader mBitmapShader; | |
private int currentRoatate = 0; | |
public RotateImage(Context context, AttributeSet attrs, int defStyle) { | |
super(context, attrs, defStyle); | |
this.mMatrix = new Matrix(); | |
this.mPaint = new Paint(); | |
this.mPaint.setAntiAlias(true); | |
} | |
public RotateImage(Context context, AttributeSet attrs) { | |
super(context, attrs, 0); | |
this.mMatrix = new Matrix(); | |
this.mPaint = new Paint(); | |
this.mPaint.setAntiAlias(true); | |
} | |
public RotateImage(Context context) { | |
super(context, (AttributeSet)null); | |
} | |
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { | |
super.onMeasure(widthMeasureSpec, heightMeasureSpec); | |
this.mWidth = Math.min(this.getMeasuredWidth(), this.getMeasuredHeight()); | |
this.mRadius = this.mWidth / 2; | |
this.setMeasuredDimension(this.mWidth, this.mWidth); | |
} | |
protected void onDraw(Canvas canvas) { | |
if(this.getDrawable() != null) { | |
this.setUpShader(); | |
canvas.drawCircle((float)this.mRadius, (float)this.mRadius, (float)this.mRadius, this.mPaint); | |
} | |
} | |
private void setUpShader() { | |
Drawable drawable = this.getDrawable(); | |
if(drawable != null) { | |
this.mBitmap = this.drawableToBitamp(drawable); | |
this.mBitmapShader = new BitmapShader(this.mBitmap, TileMode.CLAMP, TileMode.CLAMP); | |
float scale = 1.0F; | |
int bSize = Math.min(this.mBitmap.getWidth(), this.mBitmap.getHeight()); | |
scale = (float)this.mWidth * 1.0F / (float)bSize; | |
this.mMatrix.setScale(scale, scale); | |
this.mBitmapShader.setLocalMatrix(this.mMatrix); | |
this.mPaint.setShader(this.mBitmapShader); | |
this.updateShaderMatrix(); | |
this.invalidate(); | |
} | |
} | |
private Bitmap drawableToBitamp(Drawable drawable) { | |
if(drawable instanceof BitmapDrawable) { | |
BitmapDrawable w1 = (BitmapDrawable)drawable; | |
return w1.getBitmap(); | |
} else { | |
int w = drawable.getIntrinsicWidth(); | |
int h = drawable.getIntrinsicHeight(); | |
Bitmap bitmap = Bitmap.createBitmap(w, h, Config.ARGB_8888); | |
Canvas canvas = new Canvas(bitmap); | |
drawable.setBounds(0, 0, w, h); | |
drawable.draw(canvas); | |
return bitmap; | |
} | |
} | |
private void updateShaderMatrix() { | |
this.mMatrix.set((Matrix)null); | |
this.mMatrix.preRotate((float)this.currentRoatate, (float)(this.mWidth / 2), (float)(this.mWidth / 2)); | |
this.mBitmapShader.setLocalMatrix(this.mMatrix); | |
} | |
} |
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
// | |
// Source code recreated from a .class file by IntelliJ IDEA | |
// (powered by Fernflower decompiler) | |
// | |
package com.mysoft.myhome.view; | |
import android.content.Context; | |
import android.content.res.TypedArray; | |
import android.graphics.Bitmap; | |
import android.graphics.BitmapShader; | |
import android.graphics.Canvas; | |
import android.graphics.Matrix; | |
import android.graphics.Paint; | |
import android.graphics.RectF; | |
import android.graphics.Bitmap.Config; | |
import android.graphics.Shader.TileMode; | |
import android.graphics.drawable.BitmapDrawable; | |
import android.graphics.drawable.Drawable; | |
import android.os.Bundle; | |
import android.os.Parcelable; | |
import android.util.AttributeSet; | |
import android.util.Log; | |
import android.util.TypedValue; | |
import android.widget.ImageView; | |
import com.mysoft.myhome.R.styleable; | |
public class RoundImageView extends ImageView { | |
private int type; | |
public static final int TYPE_CIRCLE = 0; | |
public static final int TYPE_ROUND = 1; | |
private static final int BODER_RADIUS_DEFAULT = 10; | |
private int mBorderRadius; | |
private Paint mBitmapPaint; | |
private int mRadius; | |
private Matrix mMatrix; | |
private BitmapShader mBitmapShader; | |
private int mWidth; | |
private RectF mRoundRect; | |
private static final String STATE_INSTANCE = "state_instance"; | |
private static final String STATE_TYPE = "state_type"; | |
private static final String STATE_BORDER_RADIUS = "state_border_radius"; | |
public RoundImageView(Context context, AttributeSet attrs) { | |
super(context, attrs); | |
this.mMatrix = new Matrix(); | |
this.mBitmapPaint = new Paint(); | |
this.mBitmapPaint.setAntiAlias(true); | |
TypedArray a = context.obtainStyledAttributes(attrs, styleable.RoundImageView); | |
this.mBorderRadius = a.getDimensionPixelSize(0, (int)TypedValue.applyDimension(1, 10.0F, this.getResources().getDisplayMetrics())); | |
this.type = a.getInt(1, 0); | |
a.recycle(); | |
} | |
public RoundImageView(Context context) { | |
this(context, (AttributeSet)null); | |
} | |
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { | |
super.onMeasure(widthMeasureSpec, heightMeasureSpec); | |
if(this.type == 0) { | |
this.mWidth = Math.min(this.getMeasuredWidth(), this.getMeasuredHeight()); | |
this.mRadius = this.mWidth / 2; | |
this.setMeasuredDimension(this.mWidth, this.mWidth); | |
} | |
} | |
private void setUpShader() { | |
Drawable drawable = this.getDrawable(); | |
if(drawable != null) { | |
Bitmap bmp = this.drawableToBitamp(drawable); | |
this.mBitmapShader = new BitmapShader(bmp, TileMode.CLAMP, TileMode.CLAMP); | |
float scale = 1.0F; | |
if(this.type == 0) { | |
int bSize = Math.min(bmp.getWidth(), bmp.getHeight()); | |
scale = (float)this.mWidth * 1.0F / (float)bSize; | |
} else if(this.type == 1) { | |
Log.e("TAG", "b\'w = " + bmp.getWidth() + " , " + "b\'h = " + bmp.getHeight()); | |
if(bmp.getWidth() != this.getWidth() || bmp.getHeight() != this.getHeight()) { | |
scale = Math.max((float)this.getWidth() * 1.0F / (float)bmp.getWidth(), (float)this.getHeight() * 1.0F / (float)bmp.getHeight()); | |
} | |
} | |
this.mMatrix.setScale(scale, scale); | |
this.mBitmapShader.setLocalMatrix(this.mMatrix); | |
this.mBitmapPaint.setShader(this.mBitmapShader); | |
} | |
} | |
protected void onDraw(Canvas canvas) { | |
Log.e("TAG", "onDraw"); | |
if(this.getDrawable() != null) { | |
this.setUpShader(); | |
if(this.type == 1) { | |
canvas.drawRoundRect(this.mRoundRect, (float)this.mBorderRadius, (float)this.mBorderRadius, this.mBitmapPaint); | |
} else { | |
canvas.drawCircle((float)this.mRadius, (float)this.mRadius, (float)this.mRadius, this.mBitmapPaint); | |
} | |
} | |
} | |
protected void onSizeChanged(int w, int h, int oldw, int oldh) { | |
super.onSizeChanged(w, h, oldw, oldh); | |
if(this.type == 1) { | |
this.mRoundRect = new RectF(0.0F, 0.0F, (float)w, (float)h); | |
} | |
} | |
private Bitmap drawableToBitamp(Drawable drawable) { | |
if(drawable instanceof BitmapDrawable) { | |
BitmapDrawable w1 = (BitmapDrawable)drawable; | |
return w1.getBitmap(); | |
} else { | |
int w = drawable.getIntrinsicWidth(); | |
int h = drawable.getIntrinsicHeight(); | |
Bitmap bitmap = Bitmap.createBitmap(w, h, Config.ARGB_8888); | |
Canvas canvas = new Canvas(bitmap); | |
drawable.setBounds(0, 0, w, h); | |
drawable.draw(canvas); | |
return bitmap; | |
} | |
} | |
protected Parcelable onSaveInstanceState() { | |
Bundle bundle = new Bundle(); | |
bundle.putParcelable("state_instance", super.onSaveInstanceState()); | |
bundle.putInt("state_type", this.type); | |
bundle.putInt("state_border_radius", this.mBorderRadius); | |
return bundle; | |
} | |
protected void onRestoreInstanceState(Parcelable state) { | |
if(state instanceof Bundle) { | |
Bundle bundle = (Bundle)state; | |
super.onRestoreInstanceState(((Bundle)state).getParcelable("state_instance")); | |
this.type = bundle.getInt("state_type"); | |
this.mBorderRadius = bundle.getInt("state_border_radius"); | |
} else { | |
super.onRestoreInstanceState(state); | |
} | |
} | |
public void setBorderRadius(int borderRadius) { | |
int pxVal = this.dp2px(borderRadius); | |
if(this.mBorderRadius != pxVal) { | |
this.mBorderRadius = pxVal; | |
this.invalidate(); | |
} | |
} | |
public void setType(int type) { | |
if(this.type != type) { | |
this.type = type; | |
if(this.type != 1 && this.type != 0) { | |
this.type = 0; | |
} | |
this.requestLayout(); | |
} | |
} | |
public int dp2px(int dpVal) { | |
return (int)TypedValue.applyDimension(1, (float)dpVal, this.getResources().getDisplayMetrics()); | |
} | |
} |
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
# cache for current jar dependency. DO NOT EDIT. | |
# format is <lastModified> <length> <SHA-1> <path> | |
# Encoding is UTF-8 |
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
buildscript { | |
repositories { | |
mavenCentral() | |
} | |
dependencies { | |
classpath 'com.android.tools.build:gradle:0.5.+' | |
} | |
} | |
apply plugin: 'android' | |
dependencies { | |
compile fileTree(dir: 'libs', include: '*.jar') | |
} | |
android { | |
compileSdkVersion 19 | |
buildToolsVersion "19.0.0" | |
sourceSets { | |
main { | |
manifest.srcFile 'AndroidManifest.xml' | |
java.srcDirs = ['src'] | |
resources.srcDirs = ['src'] | |
aidl.srcDirs = ['src'] | |
renderscript.srcDirs = ['src'] | |
res.srcDirs = ['res'] | |
assets.srcDirs = ['assets'] | |
} | |
// Move the tests to tests/java, tests/res, etc... | |
instrumentTest.setRoot('tests') | |
// Move the build types to build-types/<type> | |
// For instance, build-types/debug/java, build-types/debug/AndroidManifest.xml, ... | |
// This moves them out of them default location under src/<type>/... which would | |
// conflict with src/ being used by the main source set. | |
// Adding new build types or product flavors should be accompanied | |
// by a similar customization. | |
debug.setRoot('build-types/debug') | |
release.setRoot('build-types/release') | |
} | |
} |
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
/*___Generated_by_IDEA___*/ | |
package com.mysoft.myhome; | |
/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */ | |
public final class BuildConfig { | |
public final static boolean DEBUG = Boolean.parseBoolean(null); | |
} |
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
/* 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.mysoft.myhome; | |
public final class R { | |
public static final class anim { | |
public static final int popupwindow_enter=0x7f040000; | |
public static final int popupwindow_exit=0x7f040001; | |
public static final int search_popup_enter=0x7f040002; | |
public static final int search_popup_exit=0x7f040003; | |
} | |
public static final class array { | |
public static final int search_pay_state=0x7f090002; | |
public static final int search_who=0x7f090001; | |
public static final int whopay=0x7f090000; | |
} | |
public static final class attr { | |
/** <p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". | |
Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), | |
in (inches), mm (millimeters). | |
<p>This may also be a reference to a resource (in the form | |
"<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or | |
theme attribute (in the form | |
"<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") | |
containing a value of this type. | |
*/ | |
public static final int borderRadius=0x7f010000; | |
/** <p>Must be a reference to another resource, in the form "<code>@[+][<i>package</i>:]<i>type</i>:<i>name</i></code>" | |
or to a theme attribute in the form "<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>". | |
*/ | |
public static final int src=0x7f010002; | |
/** <p>Must be one of the following constant values.</p> | |
<table> | |
<colgroup align="left" /> | |
<colgroup align="left" /> | |
<colgroup align="left" /> | |
<tr><th>Constant</th><th>Value</th><th>Description</th></tr> | |
<tr><td><code>circle</code></td><td>0</td><td></td></tr> | |
<tr><td><code>round</code></td><td>1</td><td></td></tr> | |
</table> | |
*/ | |
public static final int type=0x7f010001; | |
} | |
public static final class color { | |
public static final int RadioButton_bg_no=0x7f060000; | |
public static final int RadioButton_bg_sel=0x7f060001; | |
public static final int my_sure_btn_sel=0x7f060002; | |
public static final int popup_bg_color=0x7f060003; | |
public static final int search_popup_btn_bg_no=0x7f060004; | |
} | |
public static final class dimen { | |
/** Default screen margins, per the Android Design guidelines. | |
Customize dimensions originally defined in res/values/dimens.xml (such as | |
screen margins) for sw720dp devices (e.g. 10" tablets) in landscape here. | |
*/ | |
public static final int activity_horizontal_margin=0x7f070000; | |
public static final int activity_vertical_margin=0x7f070001; | |
} | |
public static final class drawable { | |
public static final int a11=0x7f020000; | |
public static final int add_note_no=0x7f020001; | |
public static final int add_note_sel=0x7f020002; | |
public static final int back_no=0x7f020003; | |
public static final int back_sel=0x7f020004; | |
public static final int change_state=0x7f020005; | |
public static final int dagou=0x7f020006; | |
public static final int home=0x7f020007; | |
public static final int ic_arrow_left=0x7f020008; | |
public static final int ic_arrow_right=0x7f020009; | |
public static final int ic_delete=0x7f02000a; | |
public static final int ic_launcher=0x7f02000b; | |
public static final int img_1=0x7f02000c; | |
public static final int img_2=0x7f02000d; | |
public static final int img_3=0x7f02000e; | |
public static final int img_4=0x7f02000f; | |
public static final int img_5=0x7f020010; | |
public static final int img_6=0x7f020011; | |
public static final int item_bg=0x7f020012; | |
public static final int listview_div=0x7f020013; | |
public static final int logo=0x7f020014; | |
public static final int other_no=0x7f020015; | |
public static final int other_sel=0x7f020016; | |
public static final int record_no=0x7f020017; | |
public static final int record_sel=0x7f020018; | |
public static final int search_img=0x7f020019; | |
public static final int search_no=0x7f02001a; | |
public static final int search_sel=0x7f02001b; | |
public static final int select_add_note_bg=0x7f02001c; | |
public static final int select_btn_sure=0x7f02001d; | |
public static final int selector_btn_menu_item_1=0x7f02001e; | |
public static final int selector_btn_menu_item_2=0x7f02001f; | |
public static final int selector_btn_menu_item_3=0x7f020020; | |
public static final int selector_popup_btn_cancle=0x7f020021; | |
public static final int selector_popup_btn_sure_bg=0x7f020022; | |
public static final int selector_search_pop_btn_bg=0x7f020023; | |
public static final int selector_titlebar_back=0x7f020024; | |
public static final int setting=0x7f020025; | |
public static final int shape_popup_bg=0x7f020026; | |
public static final int shape_popup_cancle_no=0x7f020027; | |
public static final int shape_popup_cancle_sel=0x7f020028; | |
public static final int shape_popup_sure_no=0x7f020029; | |
public static final int shape_popup_sure_sel=0x7f02002a; | |
public static final int tx_no=0x7f02002b; | |
public static final int user=0x7f02002c; | |
} | |
public static final class id { | |
public static final int action_settings=0x7f050062; | |
public static final int circle=0x7f050000; | |
public static final int grid_item_img_choice=0x7f050039; | |
public static final int grid_item_img_touxiang=0x7f050037; | |
public static final int grid_item_text_name=0x7f050038; | |
public static final int home_img=0x7f050008; | |
public static final int home_menu_item_btn_1=0x7f05000a; | |
public static final int home_menu_item_btn_2=0x7f05000d; | |
public static final int home_menu_item_btn_3=0x7f050010; | |
public static final int home_menu_item_text_1=0x7f05000b; | |
public static final int home_menu_item_text_2=0x7f05000e; | |
public static final int home_menu_item_text_3=0x7f050011; | |
public static final int home_menu_row1_1=0x7f050009; | |
public static final int home_menu_row1_2=0x7f05000c; | |
public static final int home_menu_row1_3=0x7f05000f; | |
public static final int home_title=0x7f050007; | |
public static final int imageView1=0x7f05004b; | |
public static final int linearLayout1=0x7f050050; | |
public static final int list_foot_bar=0x7f050036; | |
public static final int list_foot_text=0x7f050035; | |
public static final int main_btn_add_note=0x7f050031; | |
public static final int main_btn_sure=0x7f050034; | |
public static final int main_date_text=0x7f05002a; | |
public static final int main_edit_money=0x7f05002d; | |
public static final int main_gridview=0x7f050033; | |
public static final int main_le_date=0x7f050029; | |
public static final int main_le_money=0x7f05002b; | |
public static final int main_le_whopay=0x7f05002e; | |
public static final int main_whopay_spinner=0x7f050030; | |
public static final int main_whopay_text=0x7f05002f; | |
public static final int perinfo_le_1=0x7f05001b; | |
public static final int perinfo_le_2=0x7f05001f; | |
public static final int perinfo_listview=0x7f050026; | |
public static final int perinfo_re_1=0x7f05001a; | |
public static final int perinfo_spinner_name=0x7f05001c; | |
public static final int perinfo_spinner_paystate=0x7f05001d; | |
public static final int perinfo_text_allmoney=0x7f050021; | |
public static final int perinfo_text_data=0x7f05001e; | |
public static final int perinfo_text_jiesuan_money=0x7f050025; | |
public static final int perinfo_text_jiesuan_str=0x7f050024; | |
public static final int perinfo_text_money_val=0x7f050020; | |
public static final int perinfo_text_yufu_money=0x7f050023; | |
public static final int perinfo_text_yufu_str=0x7f050022; | |
public static final int perinfo_title=0x7f050019; | |
public static final int pop_btn_cancle=0x7f05004e; | |
public static final int pop_btn_sure=0x7f05004f; | |
public static final int pop_edit_note=0x7f05004c; | |
public static final int pop_le_1=0x7f05004d; | |
public static final int relativeLayout1=0x7f05003a; | |
public static final int round=0x7f050001; | |
public static final int search_all_btn=0x7f050018; | |
public static final int search_all_item_date=0x7f050051; | |
public static final int search_all_item_le_note=0x7f050054; | |
public static final int search_all_item_money=0x7f050052; | |
public static final int search_all_item_state=0x7f050059; | |
public static final int search_all_item_text_note=0x7f050056; | |
public static final int search_all_item_who=0x7f050053; | |
public static final int search_all_item_whopay=0x7f050058; | |
public static final int search_all_listview=0x7f050017; | |
public static final int search_popup_all_linear=0x7f05003e; | |
public static final int search_popup_btn_cancel=0x7f05003c; | |
public static final int search_popup_btn_linear=0x7f05003b; | |
public static final int search_popup_btn_sure=0x7f05003d; | |
public static final int search_popup_linear_1=0x7f05003f; | |
public static final int search_popup_linear_2=0x7f050044; | |
public static final int search_popup_linear_3=0x7f050047; | |
public static final int search_popup_text_date=0x7f050041; | |
public static final int search_popup_text_money=0x7f050043; | |
public static final int search_popup_text_who=0x7f050046; | |
public static final int search_popup_text_yufu=0x7f050049; | |
public static final int search_popup_wait_bar=0x7f05004a; | |
public static final int search_re=0x7f050015; | |
public static final int serach_all_titlebar=0x7f050016; | |
public static final int setting_title=0x7f050012; | |
public static final int submit_main=0x7f050027; | |
public static final int submit_title=0x7f050028; | |
public static final int tab_home=0x7f050003; | |
public static final int tab_setting=0x7f050005; | |
public static final int tab_user=0x7f050004; | |
public static final int textView1=0x7f050013; | |
public static final int textView2=0x7f050045; | |
public static final int textView3=0x7f05002c; | |
public static final int textView4=0x7f050032; | |
public static final int textView5=0x7f050055; | |
public static final int textView7=0x7f050057; | |
public static final int textView_yufu=0x7f050048; | |
public static final int text_jine=0x7f050042; | |
public static final int text_str_date=0x7f050040; | |
public static final int titlebar_back=0x7f05005b; | |
public static final int titlebar_title=0x7f05005a; | |
public static final int toast_text=0x7f050014; | |
public static final int view_content=0x7f050006; | |
public static final int view_tab=0x7f050002; | |
public static final int widgetCalendar_calendar=0x7f050061; | |
public static final int widgetCalendar_imgForeMonth=0x7f05005d; | |
public static final int widgetCalendar_imgForeYear=0x7f05005c; | |
public static final int widgetCalendar_imgNextMonth=0x7f05005f; | |
public static final int widgetCalendar_imgNextYear=0x7f050060; | |
public static final int widgetCalendar_txtTitle=0x7f05005e; | |
} | |
public static final class layout { | |
public static final int activity_main=0x7f030000; | |
public static final int fragment_layout_home=0x7f030001; | |
public static final int fragment_layout_setting=0x7f030002; | |
public static final int fragment_layout_user=0x7f030003; | |
public static final int layout_logo=0x7f030004; | |
public static final int layout_mytoast=0x7f030005; | |
public static final int layout_search_all=0x7f030006; | |
public static final int layout_search_perinfo=0x7f030007; | |
public static final int layout_submitinfo=0x7f030008; | |
public static final int listview_foot_layout=0x7f030009; | |
public static final int main_grid_item=0x7f03000a; | |
public static final int popup_layout_jiesuan=0x7f03000b; | |
public static final int popupwindow=0x7f03000c; | |
public static final int search_all_item=0x7f03000d; | |
public static final int title_bar=0x7f03000e; | |
public static final int widget_calendar=0x7f03000f; | |
} | |
public static final class menu { | |
public static final int main=0x7f0b0000; | |
} | |
public static final class string { | |
public static final int action_settings=0x7f080001; | |
public static final int app_name=0x7f080000; | |
public static final int hello_world=0x7f080002; | |
} | |
public static final class style { | |
/** | |
Base application theme, dependent on API level. This theme is replaced | |
by AppBaseTheme from res/values-vXX/styles.xml on newer devices. | |
Theme customizations available in newer API levels can go in | |
res/values-vXX/styles.xml, while customizations related to | |
backward-compatibility can go here. | |
Base application theme for API 11+. This theme completely replaces | |
AppBaseTheme from res/values/styles.xml on API 11+ devices. | |
API 11 theme customizations can go here. | |
Base application theme for API 14+. This theme completely replaces | |
AppBaseTheme from BOTH res/values/styles.xml and | |
res/values-v11/styles.xml on API 14+ devices. | |
API 14 theme customizations can go here. | |
*/ | |
public static final int AppBaseTheme=0x7f0a0000; | |
/** Application theme. | |
All customizations that are NOT specific to a particular API-level can go here. | |
*/ | |
public static final int AppTheme=0x7f0a0001; | |
public static final int popWindow_animation=0x7f0a0003; | |
public static final int search_popWindow_animation=0x7f0a0004; | |
public static final int tab_textview=0x7f0a0002; | |
} | |
public static final class styleable { | |
/** Attributes that can be used with a RoundImageView. | |
<p>Includes the following attributes:</p> | |
<table> | |
<colgroup align="left" /> | |
<colgroup align="left" /> | |
<tr><th>Attribute</th><th>Description</th></tr> | |
<tr><td><code>{@link #RoundImageView_borderRadius com.mysoft.myhome:borderRadius}</code></td><td></td></tr> | |
<tr><td><code>{@link #RoundImageView_type com.mysoft.myhome:type}</code></td><td></td></tr> | |
</table> | |
@see #RoundImageView_borderRadius | |
@see #RoundImageView_type | |
*/ | |
public static final int[] RoundImageView = { | |
0x7f010000, 0x7f010001 | |
}; | |
/** | |
<p>This symbol is the offset where the {@link com.mysoft.myhome.R.attr#borderRadius} | |
attribute's value can be found in the {@link #RoundImageView} array. | |
<p>Must be a dimension value, which is a floating point number appended with a unit such as "<code>14.5sp</code>". | |
Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), | |
in (inches), mm (millimeters). | |
<p>This may also be a reference to a resource (in the form | |
"<code>@[<i>package</i>:]<i>type</i>:<i>name</i></code>") or | |
theme attribute (in the form | |
"<code>?[<i>package</i>:][<i>type</i>:]<i>name</i></code>") | |
containing a value of this type. | |
@attr name com.mysoft.myhome:borderRadius | |
*/ | |
public static final int RoundImageView_borderRadius = 0; | |
/** | |
<p>This symbol is the offset where the {@link com.mysoft.myhome.R.attr#type} | |
attribute's value can be found in the {@link #RoundImageView} array. | |
<p>Must be one of the following constant values.</p> | |
<table> | |
<colgroup align="left" /> | |
<colgroup align="left" /> | |
<colgroup align="left" /> | |
<tr><th>Constant</th><th>Value</th><th>Description</th></tr> | |
<tr><td><code>circle</code></td><td>0</td><td></td></tr> | |
<tr><td><code>round</code></td><td>1</td><td></td></tr> | |
</table> | |
@attr name com.mysoft.myhome:type | |
*/ | |
public static final int RoundImageView_type = 1; | |
}; | |
} |
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
PK | |