first commit
This commit is contained in:
85
p000/LicenseInputForm.java
Normal file
85
p000/LicenseInputForm.java
Normal file
@@ -0,0 +1,85 @@
|
||||
package p000;
|
||||
|
||||
import com.m3gworks.engine.GameAppMidlet;
|
||||
import javax.microedition.lcdui.Command;
|
||||
import javax.microedition.lcdui.CommandListener;
|
||||
import javax.microedition.lcdui.Displayable;
|
||||
import javax.microedition.lcdui.Form;
|
||||
import javax.microedition.lcdui.TextField;
|
||||
import javax.microedition.midlet.MIDletStateChangeException;
|
||||
import javax.microedition.rms.RecordStore;
|
||||
import javax.microedition.rms.RecordStoreException;
|
||||
import javax.microedition.rms.RecordStoreFullException;
|
||||
import javax.microedition.rms.RecordStoreNotFoundException;
|
||||
|
||||
/* renamed from: ao */
|
||||
/* loaded from: microcounterstrike.jar:ao.class */
|
||||
public final class LicenseInputForm extends Form implements CommandListener {
|
||||
|
||||
/* renamed from: a */
|
||||
private TextField textField82;
|
||||
|
||||
/* renamed from: b */
|
||||
private TextField textField83;
|
||||
|
||||
/* renamed from: c */
|
||||
private Command command84;
|
||||
|
||||
/* renamed from: d */
|
||||
private Command command85;
|
||||
|
||||
public LicenseInputForm() {
|
||||
super("Registration");
|
||||
this.textField82 = null;
|
||||
this.textField83 = null;
|
||||
this.command84 = null;
|
||||
this.command85 = null;
|
||||
this.textField82 = new TextField("Your email:", (String) null, 100, 0);
|
||||
append(this.textField82);
|
||||
this.textField83 = new TextField("Serial number:", (String) null, 100, 2);
|
||||
append(this.textField83);
|
||||
this.command84 = new Command("OK", 1, 1);
|
||||
addCommand(this.command84);
|
||||
this.command85 = new Command("Exit", 1, 2);
|
||||
addCommand(this.command85);
|
||||
setCommandListener(this);
|
||||
}
|
||||
|
||||
public final void commandAction(Command command, Displayable displayable) {
|
||||
if (command != this.command84) {
|
||||
Command commandM213a = command;
|
||||
if (commandM213a == this.command85) {
|
||||
try {
|
||||
SplashScreen.execute226();
|
||||
commandM213a = GameAppMidlet.getInstance();
|
||||
commandM213a.destroyApp(false);
|
||||
} catch (MIDletStateChangeException e) {
|
||||
commandM213a.printStackTrace();
|
||||
}
|
||||
GameAppMidlet.getInstance().notifyDestroyed();
|
||||
return;
|
||||
}
|
||||
return;
|
||||
}
|
||||
if (!LicenseKeyUtil.getString100(this.textField82.getString()).equals(this.textField83.getString())) {
|
||||
setTitle("Invalid Email/SN!");
|
||||
return;
|
||||
}
|
||||
RecordStore recordStore = null;
|
||||
try {
|
||||
RecordStore recordStoreOpenRecordStore = RecordStore.openRecordStore("m3gworksMCS", true);
|
||||
byte[] bytes = "ZHANGYUNZHI".getBytes();
|
||||
recordStoreOpenRecordStore.addRecord(bytes, 0, bytes.length);
|
||||
recordStore = recordStoreOpenRecordStore;
|
||||
recordStore.closeRecordStore();
|
||||
} catch (RecordStoreNotFoundException e2) {
|
||||
recordStore.printStackTrace();
|
||||
} catch (RecordStoreFullException e3) {
|
||||
recordStore.printStackTrace();
|
||||
} catch (RecordStoreException e4) {
|
||||
recordStore.printStackTrace();
|
||||
}
|
||||
GameAppMidlet.getInstance().display.setCurrent(MainUiCanvasBase.getInstance());
|
||||
MainUiCanvasBase.getInstance().execute37();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user