Browse Source

Little fixes on code

master
Defend 8 years ago
parent
commit
9fba40e20c
  1. 6
      .gitignore
  2. 16
      app/app.iml
  3. 5
      app/src/main/java/ru/defend/defdevteam/tstu/CabinetActivity.java
  4. 1
      app/src/main/java/ru/defend/defdevteam/tstu/FeedParser.java
  5. 1
      app/src/main/java/ru/defend/defdevteam/tstu/FeedReader.java
  6. 6
      app/src/main/java/ru/defend/defdevteam/tstu/MainActivity.java
  7. 10
      app/src/main/java/ru/defend/defdevteam/tstu/OldCabinetController.java
  8. 4
      app/src/main/java/ru/defend/defdevteam/tstu/OldParser.java
  9. BIN
      app/src/main/res/mipmap-xxxhdpi/Thumbs.db

6
.gitignore

@ -1,3 +1,7 @@
[core]
excludesfile = ~/.gitexcludes
local.properties
# User-specific stuff:
.idea/workspace.xml
@ -48,7 +52,7 @@ fabric.properties
# modules.xml
# Windows thumbnail cache files
Thumbs.db
*Thumbs.db
ehthumbs.db
ehthumbs_vista.db

16
app/app.iml

@ -66,14 +66,6 @@
<sourceFolder url="file://$MODULE_DIR$/src/main/jni" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/rs" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/shaders" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/res" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/resources" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/assets" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/aidl" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/java" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/jni" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/rs" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/shaders" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/test/res" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/test/resources" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/test/assets" type="java-test-resource" />
@ -82,6 +74,14 @@
<sourceFolder url="file://$MODULE_DIR$/src/test/jni" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/test/rs" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/test/shaders" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/res" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/resources" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/assets" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/aidl" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/java" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/jni" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/rs" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/shaders" isTestSource="true" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/assets" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/blame" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/builds" />

5
app/src/main/java/ru/defend/defdevteam/tstu/CabinetActivity.java

@ -49,7 +49,6 @@ public class CabinetActivity extends AppCompatActivity
public RelativeLayout profileLayout, journalLayout, gRateLayout,
fRateLayout, aboutLayout, progressLayout, newsLayout;
public Toolbar myToolbar;
public Chronometer timer;
Intent MainA;
FeedController feedController;
OldCabinetController cabinetController;
@ -305,13 +304,13 @@ public class CabinetActivity extends AppCompatActivity
positionFaculty.setText(getString(R.string.cabinet_faculty_position) + position);
}
public void fillGroup(){
public void updateGroup(){
ArrayAdapter<GroupList> groupL = new groupAdapter(this);
ListView groupList = (ListView) findViewById(R.id.groupList);
groupList.setAdapter(groupL);
}
public void fillFaculty(){
public void updateFaculty(){
ArrayAdapter<GroupList> facultyL = new facultyAdapter(this);
ListView facultyList = (ListView) findViewById(R.id.facultyList);
facultyList.setAdapter(facultyL);

1
app/src/main/java/ru/defend/defdevteam/tstu/FeedParser.java

@ -26,5 +26,4 @@ public class FeedParser {
}
}

1
app/src/main/java/ru/defend/defdevteam/tstu/FeedReader.java

@ -29,7 +29,6 @@ public class FeedReader extends Thread implements FeedController.FeedCallback {
this.threadState = States.THREAD_NULL;
}
public void run(){
try {
this.threadState = States.THREAD_WORK;

6
app/src/main/java/ru/defend/defdevteam/tstu/MainActivity.java

@ -12,15 +12,12 @@ import android.widget.ImageView;
public class MainActivity extends AppCompatActivity {
private EditText login, password;
public ImageView logo;
private SharedPreferences sPref;
final String LOGIN = "login";
final String PASSWORD = "password";
final String CHECK = "check";
public CheckBox check;
public void authButtonOnClick(View v){
if(check.isChecked()){
saveForms();
@ -83,7 +80,4 @@ public class MainActivity extends AppCompatActivity {
if(check.isChecked()) saveForms();
}
public void OnSubsListClick(View v) {
}
}

10
app/src/main/java/ru/defend/defdevteam/tstu/OldCabinetController.java

@ -13,11 +13,13 @@ import java.util.List;
*/
public class OldCabinetController {
boolean authBegin, taskFinished = false;
static public String AuthURL, MainURL, AdditionalURL ,JournalURL, RateValueURL, GroupRateURL,
boolean taskFinished = false;
static public String MainURL, JournalURL, RateValueURL, GroupRateURL,
FacultyRateURL, siteBuf;
static public String MainHTML, AdditionalHTML, JournalHTML, RateValueHTML, GroupRateHTML,
FacultyRateHTML;
public CabinetActivity cabinetActivity;
public OldCabinetController(CabinetActivity cabinet){
@ -171,7 +173,7 @@ public class OldCabinetController {
}
gr = parser.cutLine("</td></tr>\\n", "", gr);
}
cabinetActivity.fillGroup();
cabinetActivity.updateGroup();
}
public void fillFaculty(){
@ -194,6 +196,6 @@ public class OldCabinetController {
}
fr = parser.cutLine("</td></tr>\\n", "", fr);
}
cabinetActivity.fillFaculty();
cabinetActivity.updateFaculty();
}
}

4
app/src/main/java/ru/defend/defdevteam/tstu/OldParser.java

@ -21,10 +21,6 @@ public class OldParser {
m.appendTail(buf);
return buf;
}
//
// public ArrayList<CabinetActivity.groupList> parseGroup(){
// return null;
// }
public String cutLine(String a, String b, String Line){
if(Line.contains(a)) Line = Line.substring(Line.indexOf(a)+ a.length());

BIN
app/src/main/res/mipmap-xxxhdpi/Thumbs.db

Binary file not shown.
Loading…
Cancel
Save