Subversion Repositories Projects

Rev

Rev 316 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 316 Rev 531
Line 3... Line 3...
3
 * Canvas  of DUBwise Installer
3
 * Canvas  of DUBwise Installer
4
 *                                                          
4
 *                                                          
5
 * Author:        Marcus -LiGi- Bueschleb
5
 * Author:        Marcus -LiGi- Bueschleb
6
 * Mailto:        LiGi @at@ LiGi DOTT de                    
6
 * Mailto:        LiGi @at@ LiGi DOTT de                    
7
 *
7
 *
-
 
8
 *
-
 
9
 * this class detects some propertys of the Phone
-
 
10
 *
8
 ***************************************************************/
11
 ***************************************************************/
Line 9... Line 12...
9
 
12
 
10
import javax.microedition.lcdui.*;
13
import javax.microedition.lcdui.*;
11
import java.io.*;
14
import java.io.*;
-
 
15
import javax.microedition.io.*;
Line 12... Line 16...
12
import javax.microedition.io.*;
16
import javax.microedition.rms.*;
13
 
17
 
14
public class DUBwiseInstallerCanvas
18
public class DUBwiseInstallerCanvas
15
    extends Canvas
19
    extends Canvas
Line 35... Line 39...
35
    String comports;
39
    String comports;
36
    String props;
40
    String props;
37
    // end  values to detect
41
    // end  values to detect
Line 38... Line 42...
38
 
42
 
-
 
43
    DUBwiseInstaller root;
-
 
44
    private boolean fs_check=true; // fullscreen check 
-
 
45
 
-
 
46
 
-
 
47
 
-
 
48
 
-
 
49
    public String description_str()
-
 
50
    {
-
 
51
 
-
 
52
        int rms_avail=0;
-
 
53
        try {
-
 
54
            RecordStore recStore = RecordStore.openRecordStore("test", true );
-
 
55
            rms_avail=recStore.getSizeAvailable();
-
 
56
            }
-
 
57
        catch ( Exception e) {}
-
 
58
        System.gc();  // to have better results measuring the Mem
-
 
59
        return
-
 
60
           
-
 
61
            "Screenwidth:" + canvas_width + "\n"
-
 
62
            +"Screenheight:" + canvas_height + "\n"
-
 
63
            +"Screenwidth FS:" + canvas_full_width + "\n"
-
 
64
            +"Screenheight FS:" + canvas_full_height + "\n"
-
 
65
            +"CLDC1.1:" + cldc11 + "\n"
-
 
66
            +"JSR-82:" + bluetooth + "\n"
-
 
67
            +"JSR-179:" + locationprovider + "\n"
-
 
68
            +"FileConn:" + fileapi + "\n"
-
 
69
            +"SensorAPI:" + sensorapi + "\n"
-
 
70
            +"DeviceControl:" + devicecontrol + "\n"
-
 
71
            +"comports:" + comports + "\n"
-
 
72
 
-
 
73
            +"freeMemory:" + Runtime.getRuntime().freeMemory()+ "\n"
-
 
74
            +"totalMemory:" + Runtime.getRuntime().totalMemory()+ "\n"
-
 
75
            +"RMSAvail:" +  rms_avail+ "\n"
-
 
76
            +props;
-
 
77
 
-
 
78
    }
Line 39... Line 79...
39
    DUBwiseInstaller root;
79
 
40
 
80
 
41
    public boolean try_class(String class_name)
81
    public boolean try_class(String class_name)
42
    {
82
    {
Line 97... Line 137...
97
            props+="symbian: true\n";
137
            props+="symbian: true\n";
98
        }
138
        }
99
        catch (ClassNotFoundException e) {
139
        catch (ClassNotFoundException e) {
100
            props+="symbian: false\n";
140
            props+="symbian: false\n";
101
        }
141
        }
102
        root.quit();
142
        root.canvas_hw_detect_finish();
Line 103... Line 143...
103
 
143
 
Line 104... Line -...
104
    }
-
 
105
 
-
 
106
 
144
    }
107
    boolean fs_check=true;
145
 
Line 108... Line 146...
108
 
146
 
109
    public void paint(Graphics g)
147
    public void paint(Graphics g)