⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 h.java

📁 webviwer,一个基于j2me的浏览器
💻 JAVA
📖 第 1 页 / 共 2 页
字号:
        break MISSING_BLOCK_LABEL_301;
        Exception exception;
        exception;
        if(recordstore != null)
            recordstore.closeRecordStore();
        throw exception;
    }

    private void a(int i1, int j1)
        throws RecordStoreException
    {
        RecordStore recordstore = null;
        recordstore = RecordStore.openRecordStore(q, false);
        byte abyte0[] = recordstore.getRecord(i[0][i1].a);
        byte abyte1[] = recordstore.getRecord(i[0][j1].a);
        recordstore.setRecord(i[0][j1].a, abyte0, 0, abyte0.length);
        recordstore.setRecord(i[0][i1].a, abyte1, 0, abyte1.length);
        String s1 = i[0][i1].c;
        String s2 = i[0][j1].c;
        Image image = i[0][i1].b;
        Image image1 = i[0][j1].b;
        i[0][j1].c = s1;
        i[0][j1].b = image;
        i[0][i1].c = s2;
        i[0][i1].b = image1;
        if(f != null)
        {
            f.setSelectedIndex(i1, true);
            f.set(i1, s2, image1);
            f.set(j1, s1, image);
        }
        if(recordstore != null)
            recordstore.closeRecordStore();
        break MISSING_BLOCK_LABEL_255;
        Exception exception;
        exception;
        if(recordstore != null)
            recordstore.closeRecordStore();
        throw exception;
    }

    public void commandAction(Command command, Displayable displayable)
    {
        try
        {
            try
            {
                if(command == e || command == List.SELECT_COMMAND && displayable == f)
                {
                    int i1 = f.getSelectedIndex();
                    if(i[0][i1].b != null)
                    {
                        String s3 = i[0][i1].c;
                        String s6 = a(i[0][i1].a);
                        i[1] = i[0];
                        i[0] = null;
                        a(s3, s6);
                    } else
                    {
                        j.a(a(i[0][i1].a), false);
                        i[0] = i[1];
                        i[1] = null;
                        f = null;
                        q = "bookmarks";
                    }
                } else
                if(command == t)
                {
                    m = f.getSelectedIndex();
                    if(i[0][m].b != null)
                    {
                        s = new Form("Delete?");
                        s.append("Are you sure you want to delete this folder and any contained bookmarks?");
                        s.addCommand(C);
                        s.addCommand(p);
                        s.setCommandListener(this);
                        x.setCurrent(s);
                    } else
                    {
                        b();
                    }
                } else
                if(command == z)
                {
                    int j1 = f.getSelectedIndex();
                    if(j1 != 0)
                        a(j1 - 1, j1);
                } else
                if(command == l)
                {
                    int k1 = f.getSelectedIndex();
                    if(k1 != f.size() - 1)
                        a(k1 + 1, k1);
                } else
                if(command == g)
                {
                    m = f.getSelectedIndex();
                    if(i[0][m].b != null)
                    {
                        x.setCurrent(new Alert(null, "Folders cannot be moved to folders", null, AlertType.ERROR), f);
                    } else
                    {
                        if(f.getTitle() == "Bookmarks")
                            i[1] = i[0];
                        h = new List("Select Folder", 3);
                        h.append("Top Level", A);
                        for(int l1 = 0; l1 < i[1].length; l1++)
                            if(i[1][l1].b != null)
                                h.append(i[1][l1].c, A);

                        h.addCommand(u);
                        h.addCommand(p);
                        h.setCommandListener(this);
                        x.setCurrent(h);
                    }
                } else
                if(command == k)
                {
                    if(!q.equals("bookmarks"))
                    {
                        q = "bookmarks";
                        i[0] = i[1];
                        i[1] = null;
                        a("Bookmarks", ((String) (null)));
                    } else
                    {
                        x.setCurrent(o);
                    }
                } else
                if(command == n)
                {
                    m = f.getSelectedIndex();
                    if(i[0][m].b == null)
                    {
                        b.setString(i[0][m].c);
                        String s1 = a(i[0][m].a);
                        if(s1.length() > c.getMaxSize() && c.setMaxSize(s1.length()) < s1.length())
                            s1 = s1.substring(0, c.getMaxSize());
                        c.setString(s1);
                        x.setCurrent(w);
                    } else
                    {
                        D.setString(i[0][m].c);
                        x.setCurrent(v);
                    }
                } else
                if(command == y)
                {
                    m = -1;
                    b.setString(null);
                    c.setString("http://");
                    x.setCurrent(w);
                } else
                if(command == r)
                {
                    m = -1;
                    D.setString(null);
                    x.setCurrent(v);
                } else
                if(command == u || command == List.SELECT_COMMAND && displayable == h)
                {
                    int i2 = h.getSelectedIndex();
                    String s4 = h.getString(i2);
                    String s7 = "bookmarks";
                    boolean flag = false;
                    if(!s4.equals("Top Level"))
                    {
                        for(int j2 = 0; j2 < i[1].length; j2++)
                        {
                            if(!i[1][j2].c.equals(s4))
                                continue;
                            flag = s4.equals(f.getTitle());
                            String s9 = q;
                            q = "bookmarks";
                            s7 = s7 + a(i[1][j2].a);
                            q = s9;
                            break;
                        }

                    } else
                    {
                        flag = f.getTitle() == "Bookmarks";
                    }
                    if(!flag)
                    {
                        String s8 = a(i[0][m].a);
                        a(i[0][m].c, s8, s7, 1);
                        b();
                    }
                    e();
                    x.setCurrent(f);
                } else
                if(command == C)
                {
                    if(displayable != s)
                    {
                        String s5 = null;
                        String s2;
                        if(displayable == w)
                        {
                            s2 = b.getString();
                            s5 = c.getString();
                        } else
                        {
                            s2 = D.getString();
                            if(m >= 0)
                                s5 = a(i[0][m].a);
                        }
                        if(m >= 0)
                            b(s2, s5);
                        else
                            a(s2, s5, q, 2);
                    } else
                    {
                        b();
                        s = null;
                    }
                    e();
                    x.setCurrent(f);
                } else
                if(command == p)
                {
                    e();
                    s = null;
                    x.setCurrent(f);
                }
            }
            catch(Exception exception)
            {
                if(f != null)
                    a(exception, f);
                else
                    a(exception, o);
            }
        }
        catch(OutOfMemoryError outofmemoryerror)
        {
            j.g();
        }
    }

    private void a(String s1)
        throws RecordStoreException, IOException
    {
        RecordStore recordstore;
        RecordEnumeration recordenumeration;
        recordstore = null;
        recordenumeration = null;
        boolean flag = false;
        q = "bookmarks";
        if(s1 == null) goto _L2; else goto _L1
_L1:
        new StringBuffer();
        this;
        JVM INSTR dup_x1 ;
        q;
        append();
        s1;
        append();
        toString();
        q;
_L2:
        recordstore = RecordStore.openRecordStore(q, false);
        recordenumeration = recordstore.enumerateRecords(null, null, false);
        int j1 = recordenumeration.numRecords();
        i[0] = new j[j1];
        for(int l1 = 0; l1 < j1 && recordenumeration.hasNextElement(); l1++)
        {
            int j2 = recordenumeration.nextRecordId();
            DataInputStream datainputstream = new DataInputStream(new ByteArrayInputStream(recordstore.getRecord(j2)));
            int k2 = l1;
            i[0][k2] = new j();
            i[0][k2].c = datainputstream.readUTF();
            i[0][k2].a = j2;
            try
            {
                int i1 = Integer.parseInt(datainputstream.readUTF());
                if(i1 > B)
                    B = i1;
                if(datainputstream.readBoolean())
                    i[0][k2].b = A;
            }
            catch(Exception exception) { }
        }

        if(recordenumeration != null)
            recordenumeration.destroy();
        if(recordstore != null)
            recordstore.closeRecordStore();
        break MISSING_BLOCK_LABEL_315;
        RecordStoreNotFoundException recordstorenotfoundexception;
        recordstorenotfoundexception;
        i[0] = new j[0];
        if(recordenumeration != null)
            recordenumeration.destroy();
        if(recordstore != null)
            recordstore.closeRecordStore();
        break MISSING_BLOCK_LABEL_315;
        Exception exception1;
        exception1;
        if(recordenumeration != null)
            recordenumeration.destroy();
        if(recordstore != null)
            recordstore.closeRecordStore();
        throw exception1;
        for(int l2 = 1; l2 < i[0].length; l2++)
        {
            int i2 = l2;
            j j3 = i[0][l2];
            for(int k1 = j3.a; i2 > 0 && i[0][i2 - 1].a > k1; i2--)
                i[0][i2] = i[0][i2 - 1];

            i[0][i2] = j3;
        }

        return;
    }

    private void a(String s1, String s2)
        throws RecordStoreException, IOException
    {
        if(i[0] == null)
            a(s2);
        f = new List(s1, 3);
        for(int i1 = 0; i1 < i[0].length; i1++)
            f.append(i[0][i1].c, i[0][i1].b);

        if(d())
            c();
        f.addCommand(k);
        e();
        if(s2 == null)
            f.addCommand(r);
        f.setCommandListener(this);
        x.setCurrent(f);
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -