|
@@ -8,6 +8,7 @@ import android.view.Menu;
|
|
|
import android.view.View;
|
|
import android.view.View;
|
|
|
import android.view.View.OnClickListener;
|
|
import android.view.View.OnClickListener;
|
|
|
import android.widget.ImageButton;
|
|
import android.widget.ImageButton;
|
|
|
|
|
+import android.widget.TextView;
|
|
|
|
|
|
|
|
public class FunctionSelectActivity extends FragmentActivity implements OnClickListener
|
|
public class FunctionSelectActivity extends FragmentActivity implements OnClickListener
|
|
|
{
|
|
{
|
|
@@ -21,24 +22,24 @@ public class FunctionSelectActivity extends FragmentActivity implements OnClickL
|
|
|
user=getIntent().getStringExtra("user");
|
|
user=getIntent().getStringExtra("user");
|
|
|
password= getIntent().getStringExtra("password");
|
|
password= getIntent().getStringExtra("password");
|
|
|
super.onCreate(savedInstanceState);
|
|
super.onCreate(savedInstanceState);
|
|
|
- setContentView(R.layout.activity_function_select);
|
|
|
|
|
-
|
|
|
|
|
- ImageButton ibtn_booking = (ImageButton)findViewById(R.id.ibtn_booking);
|
|
|
|
|
- ibtn_booking.setOnClickListener(this);
|
|
|
|
|
- ImageButton ibtn_info = (ImageButton)findViewById(R.id.ibtn_info);
|
|
|
|
|
- ibtn_info.setOnClickListener(this);
|
|
|
|
|
- ImageButton ibtn_detail = (ImageButton)findViewById(R.id.ibtn_detail);
|
|
|
|
|
- ibtn_detail.setOnClickListener(this);
|
|
|
|
|
- ImageButton ibtn_cargo = (ImageButton)findViewById(R.id.ibtn_cargo);
|
|
|
|
|
- ibtn_cargo.setOnClickListener(this);
|
|
|
|
|
- ImageButton ibtn_doc = (ImageButton)findViewById(R.id.ibtn_doc);
|
|
|
|
|
- ibtn_doc.setOnClickListener(this);
|
|
|
|
|
- ImageButton ibtn_password = (ImageButton)findViewById(R.id.ibtn_password);
|
|
|
|
|
- ibtn_password.setOnClickListener(this);
|
|
|
|
|
- ImageButton ibtn_exit = (ImageButton)findViewById(R.id.ibtn_exit);
|
|
|
|
|
- ibtn_exit.setOnClickListener(this);
|
|
|
|
|
- ImageButton ibtn_loc = (ImageButton)findViewById(R.id.ibtn_location);
|
|
|
|
|
- ibtn_loc.setOnClickListener(this);
|
|
|
|
|
|
|
+ setContentView(R.layout.new_function_select);
|
|
|
|
|
+//
|
|
|
|
|
+ TextView tv_booking = (TextView)findViewById(R.id.tv_booking);
|
|
|
|
|
+ tv_booking.setOnClickListener(this);
|
|
|
|
|
+ TextView tv_info = (TextView)findViewById(R.id.tv_info);
|
|
|
|
|
+ tv_info.setOnClickListener(this);
|
|
|
|
|
+ TextView tv_detail = (TextView)findViewById(R.id.tv_detail);
|
|
|
|
|
+ tv_detail.setOnClickListener(this);
|
|
|
|
|
+// TextView tv_cargo = (TextView)findViewById(R.id.tv_cargo);
|
|
|
|
|
+// tv_cargo.setOnClickListener(this);
|
|
|
|
|
+ TextView tv_doc = (TextView)findViewById(R.id.tv_doc);
|
|
|
|
|
+ tv_doc.setOnClickListener(this);
|
|
|
|
|
+ TextView tv_password = (TextView)findViewById(R.id.tv_password);
|
|
|
|
|
+ tv_password.setOnClickListener(this);
|
|
|
|
|
+ TextView tv_exit = (TextView)findViewById(R.id.tv_exit);
|
|
|
|
|
+ tv_exit.setOnClickListener(this);
|
|
|
|
|
+ TextView tv_loc = (TextView)findViewById(R.id.tv_location);
|
|
|
|
|
+ tv_loc.setOnClickListener(this);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
@Override
|
|
@@ -57,7 +58,7 @@ public class FunctionSelectActivity extends FragmentActivity implements OnClickL
|
|
|
Log.d(TAG, "ID="+v.getId());
|
|
Log.d(TAG, "ID="+v.getId());
|
|
|
switch (v.getId())
|
|
switch (v.getId())
|
|
|
{
|
|
{
|
|
|
- case R.id.ibtn_booking:
|
|
|
|
|
|
|
+ case R.id.tv_booking:
|
|
|
{
|
|
{
|
|
|
Intent intent = new Intent();
|
|
Intent intent = new Intent();
|
|
|
intent.setClass(this, SearchListActivity.class);
|
|
intent.setClass(this, SearchListActivity.class);
|
|
@@ -67,7 +68,7 @@ public class FunctionSelectActivity extends FragmentActivity implements OnClickL
|
|
|
startActivity(intent);
|
|
startActivity(intent);
|
|
|
break;
|
|
break;
|
|
|
}
|
|
}
|
|
|
- case R.id.ibtn_info:
|
|
|
|
|
|
|
+ case R.id.tv_info:
|
|
|
{
|
|
{
|
|
|
Intent intent = new Intent();
|
|
Intent intent = new Intent();
|
|
|
intent.setClass(this, SearchListActivity.class);
|
|
intent.setClass(this, SearchListActivity.class);
|
|
@@ -77,7 +78,7 @@ public class FunctionSelectActivity extends FragmentActivity implements OnClickL
|
|
|
startActivity(intent);
|
|
startActivity(intent);
|
|
|
break;
|
|
break;
|
|
|
}
|
|
}
|
|
|
- case R.id.ibtn_detail:
|
|
|
|
|
|
|
+ case R.id.tv_detail:
|
|
|
{
|
|
{
|
|
|
Intent intent = new Intent();
|
|
Intent intent = new Intent();
|
|
|
intent.setClass(this, SearchListActivity.class);
|
|
intent.setClass(this, SearchListActivity.class);
|
|
@@ -87,30 +88,30 @@ public class FunctionSelectActivity extends FragmentActivity implements OnClickL
|
|
|
startActivity(intent);
|
|
startActivity(intent);
|
|
|
break;
|
|
break;
|
|
|
}
|
|
}
|
|
|
- case R.id.ibtn_cargo:
|
|
|
|
|
- {
|
|
|
|
|
- Intent intent = new Intent();
|
|
|
|
|
- intent.setClass(this, CargoTrackingActivity.class);
|
|
|
|
|
- intent.putExtra("user", user);
|
|
|
|
|
- intent.putExtra("password", password);
|
|
|
|
|
- intent.putExtra("function_name", "Cargo Tracking");
|
|
|
|
|
- startActivity(intent);
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- break;
|
|
|
|
|
- case R.id.ibtn_doc:
|
|
|
|
|
|
|
+// case R.id.tv_cargo:
|
|
|
|
|
+// {
|
|
|
|
|
+// Intent intent = new Intent();
|
|
|
|
|
+// intent.setClass(this, CargoTrackingActivity.class);
|
|
|
|
|
+// intent.putExtra("user", user);
|
|
|
|
|
+// intent.putExtra("password", password);
|
|
|
|
|
+// intent.putExtra("function_name", "Cargo Tracking");
|
|
|
|
|
+// startActivity(intent);
|
|
|
|
|
+// }
|
|
|
|
|
+//
|
|
|
|
|
+// break;
|
|
|
|
|
+ case R.id.tv_doc:
|
|
|
|
|
|
|
|
break;
|
|
break;
|
|
|
- case R.id.ibtn_password:
|
|
|
|
|
|
|
+ case R.id.tv_password:
|
|
|
|
|
|
|
|
break;
|
|
break;
|
|
|
- case R.id.ibtn_exit:
|
|
|
|
|
|
|
+ case R.id.tv_exit:
|
|
|
{
|
|
{
|
|
|
finish();
|
|
finish();
|
|
|
System.exit(0);
|
|
System.exit(0);
|
|
|
break;
|
|
break;
|
|
|
}
|
|
}
|
|
|
- case R.id.ibtn_location:
|
|
|
|
|
|
|
+ case R.id.tv_location:
|
|
|
{
|
|
{
|
|
|
Log.d("==============", "start location activity");
|
|
Log.d("==============", "start location activity");
|
|
|
Intent intent = new Intent();
|
|
Intent intent = new Intent();
|