提交 ca7f2192 authored 作者: Thomas Mueller's avatar Thomas Mueller

H2 Console: auto-complete is now disabled by default, but there is a hot-key (Ctrl+Space).

上级 95ac7161
......@@ -18,10 +18,11 @@ Change Log
<h1>Change Log</h1>
<h2>Next Version (unreleased)</h2>
<ul><li>Issue 368: ON DUPLICATE KEY UPDATE did not work for multi-row inserts.
<ul><li>Issue 551: the datatype documentation was incorrect (found by Bernd Eckenfels).
</li><li>Issue 368: ON DUPLICATE KEY UPDATE did not work for multi-row inserts.
Test case from Angus Macdonald.
</li><li>OSGi: the package javax.tools is now imported (as an optional).
</li><li>H2 Console: auto-complete is now triggered by the tab key.
</li><li>H2 Console: auto-complete is now disabled by default, but there is a hot-key (Ctrl+Space).
</li><li>H2 Console: auto-complete did not work with multi-line statements.
</li><li>CLOB and BLOB data was not immediately removed after a rollback.
</li><li>There is a new Aggregate API that supports the internal H2 data types
......
......@@ -300,6 +300,9 @@ public class WebApp {
String key = entry.getKey();
String value = entry.getValue();
String type = "" + key.charAt(0);
if (Integer.parseInt(type) > 2) {
continue;
}
key = key.substring(2);
if (Character.isLetter(key.charAt(0)) && lowercase) {
key = StringUtils.toLowerEnglish(key);
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Ukázka SQL skriptu
helpStatements=SQL příkazy
helpUpdate=Změnit hodnotu v řádku
helpWithColumnsIdName=obsahující sloupce ID a NAME
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Připojit
login.driverClass=Třída ovladače
login.driverNotFound=Ovladač k databázi nebyl nalezen<br />Postup pro přidání ovladače naleznete v sekci Nápověda
......@@ -101,8 +106,8 @@ toolbar.history=Historie příkazů
toolbar.maxRows=Maximum řádků
toolbar.refresh=Aktualizovat
toolbar.rollback=Vrátit změny
toolbar.run=Provést příkaz (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Provést příkaz
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=SQL příkaz
tools.backup=Zálohovat
tools.backup.help=Provede zálohu databáze.
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Beispiel SQL Skript
helpStatements=SQL Befehle
helpUpdate=Ändert Daten in einer Zeile
helpWithColumnsIdName=mit zwei Spalten
key.alt=Alt
key.ctrl=Strg
key.enter=Enter
key.shift=Umsch
key.space=Leer
login.connect=Verbinden
login.driverClass=Datenbank-Treiber Klasse
login.driverNotFound=Datenbank-Treiber nicht gefunden<br />Für Informationen zum Hinzufügen von Treibern siehe Hilfe
......@@ -101,8 +106,8 @@ toolbar.history=Befehls-Chronik
toolbar.maxRows=Maximale Anzahl Zeilen
toolbar.refresh=Aktualisieren
toolbar.rollback=Rollback (Rückgängig)
toolbar.run=Ausführen (Strg+Enter)
toolbar.runSelected=Ausgewähltes Ausführen (Umsch+Enter)
toolbar.run=Ausführen
toolbar.runSelected=Ausgewähltes Ausführen
toolbar.sqlStatement=SQL Befehl
tools.backup=Backup
tools.backup.help=Erzeugt eine Sichheitskopie eine Datenbank.
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Sample SQL Script
helpStatements=SQL statements
helpUpdate=Change data in a row
helpWithColumnsIdName=with ID and NAME columns
key.alt=Alt
key.ctrl=Ctrl
key.enter=Enter
key.shift=Shift
key.space=Space
login.connect=Connect
login.driverClass=Driver Class
login.driverNotFound=Database driver not found<br />See in the Help for how to add drivers
......@@ -101,8 +106,8 @@ toolbar.history=Command history
toolbar.maxRows=Max rows
toolbar.refresh=Refresh
toolbar.rollback=Rollback
toolbar.run=Run (Ctrl+Enter)
toolbar.runSelected=Run Selected (Shift+Enter)
toolbar.run=Run
toolbar.runSelected=Run Selected
toolbar.sqlStatement=SQL statement
tools.backup=Backup
tools.backup.help=Creates a backup of a database.
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Ejemplo SQL Script
helpStatements=Sentencias SQL
helpUpdate=Modificar datos en una fila
helpWithColumnsIdName=con las columnas ID y NAME
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Conectar
login.driverClass=Controlador
login.driverNotFound=Controlador no encontrado
......@@ -101,8 +106,8 @@ toolbar.history=Histórico comandos
toolbar.maxRows=Número máximo de filas
toolbar.refresh=Actualizar
toolbar.rollback=Rollback
toolbar.run=Ejecutar (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Ejecutar
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=Instrucción SQL
tools.backup=#Backup
tools.backup.help=#Creates a backup of a database.
......@@ -126,7 +131,7 @@ tools.recover.help=#Helps recovering a corrupted database.
tools.restore=#Restore
tools.restore.help=#Restores a database backup.
tools.result=#Result
tools.run=#Run
tools.run=Ejecutar
tools.runScript=#RunScript
tools.runScript.help=#Runs a SQL script.
tools.script=#Script
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Exemple de script SQL
helpStatements=Instructions SQL
helpUpdate=Modifier un enregistrement
helpWithColumnsIdName=avec les colonnes ID et NAME
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Connecter
login.driverClass=Pilote JDBC
login.driverNotFound=Pilote non trouvé.<br />Veuillez consulter dans l'aide la procédure d'ajout de pilotes.
......@@ -101,8 +106,8 @@ toolbar.history=Historique des instructions
toolbar.maxRows=Max lignes
toolbar.refresh=Rafraîchir
toolbar.rollback=Revenir en arrière
toolbar.run=Exécuter (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Exécuter
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=Instruction SQL
tools.backup=Sauvegarde
tools.backup.help=Crée une sauvegarde de base de données.
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Minta SQL szkript
helpStatements=SQL utasítások
helpUpdate=Adatok módosítása egy rekordon belül
helpWithColumnsIdName=ID és NAME oszlopokkal
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Csatlakozás
login.driverClass=Illesztőprogram osztály
login.driverNotFound=Adatbázis-illesztőprogram nem található<br>Illesztőprogramok hozzáadásáról a Súgó ad felvilágosítást.
......@@ -101,8 +106,8 @@ toolbar.history=Korábbi utasítások
toolbar.maxRows=Rekordok maximális száma
toolbar.refresh=Frissítés
toolbar.rollback=Visszagörgetés
toolbar.run=Végrehajtás (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Végrehajtás
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=SQL utasítás
tools.backup=#Backup
tools.backup.help=#Creates a backup of a database.
......@@ -126,7 +131,7 @@ tools.recover.help=#Helps recovering a corrupted database.
tools.restore=#Restore
tools.restore.help=#Restores a database backup.
tools.result=#Result
tools.run=#Run
tools.run=Végrehajtás
tools.runScript=#RunScript
tools.runScript.help=#Runs a SQL script.
tools.script=#Script
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Contoh skrip SQL
helpStatements=Pernyataan SQL
helpUpdate=Rubah data dalam sebuah baris
helpWithColumnsIdName=dengan kolom ID dan NAME
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Hubungkan
login.driverClass=Kelas Pengendali
login.driverNotFound=Pengendali basis data tidak ditemukan<br />Pelajari bagian Bantuan untuk mengetahui bagaimana cara menambah pengendali basis data
......@@ -101,8 +106,8 @@ toolbar.history=Sejarah perintah
toolbar.maxRows=Baris maksimum
toolbar.refresh=Segarkan
toolbar.rollback=Gulung mundur
toolbar.run=Jalankan (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Jalankan
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=Pernyataan SQL
tools.backup=#Backup
tools.backup.help=#Creates a backup of a database.
......@@ -126,7 +131,7 @@ tools.recover.help=#Helps recovering a corrupted database.
tools.restore=#Restore
tools.restore.help=#Restores a database backup.
tools.result=#Result
tools.run=#Run
tools.run=Jalankan
tools.runScript=#RunScript
tools.runScript.help=#Runs a SQL script.
tools.script=#Script
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Programma SQL di esempio
helpStatements=Comandi SQL
helpUpdate=Cambia dei dati in una riga
helpWithColumnsIdName=tramite ID e NOME colonne
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=Invio
key.shift=#Shift
key.space=#Space
login.connect=Connetti
login.driverClass=Classe driver
login.driverNotFound=Il driver del database non è stato trovato<br />Guardare in Aiuto su come aggiungere dei drivers
......@@ -101,8 +106,8 @@ toolbar.history=Comandi eseguiti
toolbar.maxRows=Massimo numero righe
toolbar.refresh=Aggiorna
toolbar.rollback=Annulla comando
toolbar.run=Esegui (Ctrl+Invio)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Esegui
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=Comando SQL
tools.backup=Backup
tools.backup.help=Crea un backup del database.
......
......@@ -55,6 +55,11 @@ helpSampleSQL=SQLステートメントのサンプル
helpStatements=SQLステートメント
helpUpdate=行データの変更
helpWithColumnsIdName=新しいテーブルを作成
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=接続
login.driverClass=ドライバクラス
login.driverNotFound=データベースドライバが見付かりません<br />ヘルプでドライバの追加方法を確認してください
......@@ -101,8 +106,8 @@ toolbar.history=コマンド履歴
toolbar.maxRows=最大行数
toolbar.refresh=リフレッシュ
toolbar.rollback=ロールバック
toolbar.run=実行 (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=実行
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=SQLステートメント
tools.backup=バックアップ
tools.backup.help=データベースのバックアップを作成します。
......
......@@ -55,6 +55,11 @@ helpSampleSQL=샘플 SQL 스크립트
helpStatements=SQL 문
helpUpdate=행 데이터 변경
helpWithColumnsIdName=컬럼은 ID와 NAME
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=엔터
key.shift=#Shift
key.space=#Space
login.connect=연결
login.driverClass=드라이버 클래스
login.driverNotFound=데이터베이스 드라이버를 찾지 못함<br />도움말에서 드라이버 추가 방법 참고
......@@ -101,8 +106,8 @@ toolbar.history=명령 이력
toolbar.maxRows=최대 행 수
toolbar.refresh=새로 고침
toolbar.rollback=롤백
toolbar.run=실행 (Ctrl+엔터)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=실행
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=SQL 문
tools.backup=백업
tools.backup.help=데이터베이스 백업 만들기.
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Voorbeeld SQL-script
helpStatements=SQL-statements
helpUpdate=Verander de gegevens in een rij
helpWithColumnsIdName=met de kolommen ID en NAME
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Verbind
login.driverClass=Driver klasse
login.driverNotFound=Driver voor database niet gevonden<br />Kijk in de help hoe je drivers kunt toevoegen
......@@ -101,8 +106,8 @@ toolbar.history=Geschiedenis commando's
toolbar.maxRows=Max rijen
toolbar.refresh=Verversen
toolbar.rollback=Rollback
toolbar.run=Uitvoeren (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Uitvoeren
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=SQL statement
tools.backup=#Backup
tools.backup.help=#Creates a backup of a database.
......@@ -126,7 +131,7 @@ tools.recover.help=#Helps recovering a corrupted database.
tools.restore=#Restore
tools.restore.help=#Restores a database backup.
tools.result=#Result
tools.run=#Run
tools.run=Uitvoeren
tools.runScript=#RunScript
tools.runScript.help=#Runs a SQL script.
tools.script=#Script
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Prosty skrypt SQL
helpStatements=Wyrażenia SQL
helpUpdate=Zmień dane w rekordzie
helpWithColumnsIdName=z kolumnami ID i NAME
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Połącz
login.driverClass=Klasa sterownika
login.driverNotFound=Sterownik nie istnieje<br />Zobacz w dokumentacji opis dodawania sterowników
......@@ -101,8 +106,8 @@ toolbar.history=Historia komend
toolbar.maxRows=Maksymalna ilość rekordów
toolbar.refresh=Odśwież
toolbar.rollback=Cofnij zmiany
toolbar.run=Wykonaj (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Wykonaj
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=Zapytanie SQL
tools.backup=Backup
tools.backup.help=Twozy kopie bezpieczenstwa bazy danych.
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Scripts de exemplo
helpStatements=Comandos SQL
helpUpdate=Alterar os dados de uma linha
helpWithColumnsIdName=com as colunas ID e NAME
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Conectar
login.driverClass=Classe com o driver
login.driverNotFound=O driver não foi encontrado<br/>Ver na seção de ajuda, como adicionar drivers
......@@ -101,8 +106,8 @@ toolbar.history=Histórico de comandos executados
toolbar.maxRows=Número máximo de linhas
toolbar.refresh=Atualizar
toolbar.rollback=Rollback
toolbar.run=Executar comando (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Executar comando
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=Comando SQL
tools.backup=#Backup
tools.backup.help=#Creates a backup of a database.
......@@ -126,7 +131,7 @@ tools.recover.help=#Helps recovering a corrupted database.
tools.restore=#Restore
tools.restore.help=#Restores a database backup.
tools.result=#Result
tools.run=#Run
tools.run=Executar comando
tools.runScript=#RunScript
tools.runScript.help=#Runs a SQL script.
tools.script=#Script
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Scripts de exemplo
helpStatements=Comandos SQL
helpUpdate=Modificar os dados de uma linha
helpWithColumnsIdName=com as colunas ID e NAME
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Estabelecer conexão
login.driverClass=Classe com o driver
login.driverNotFound=O driver não foi encontrado<br/>Ver na secção de ajuda, como adicionar drivers
......@@ -101,8 +106,8 @@ toolbar.history=Histórico de comandos executados
toolbar.maxRows=Número máximo de linhas
toolbar.refresh=Actualizar
toolbar.rollback=Rollback
toolbar.run=Executar comando (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Executar comando
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=Comando SQL
tools.backup=#Backup
tools.backup.help=#Creates a backup of a database.
......@@ -126,7 +131,7 @@ tools.recover.help=#Helps recovering a corrupted database.
tools.restore=#Restore
tools.restore.help=#Restores a database backup.
tools.result=#Result
tools.run=#Run
tools.run=Executar comando
tools.runScript=#RunScript
tools.runScript.help=#Runs a SQL script.
tools.script=#Script
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Примеры SQL-скриптов
helpStatements=SQL-запрос
helpUpdate=Изменить данные в строке
helpWithColumnsIdName=с колонками ID и NAME
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Соединиться
login.driverClass=Класс драйвера
login.driverNotFound=Драйвер базы данных не найден<br />Посмотрите в Помощи, как добавить драйвер базы данных
......@@ -101,8 +106,8 @@ toolbar.history=История команд
toolbar.maxRows=Максимальное количество строк
toolbar.refresh=Обновить
toolbar.rollback=Вернуть назад
toolbar.run=Выполнить (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Выполнить
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=SQL-запрос
tools.backup=#Backup
tools.backup.help=#Creates a backup of a database.
......@@ -126,7 +131,7 @@ tools.recover.help=#Helps recovering a corrupted database.
tools.restore=#Restore
tools.restore.help=#Restores a database backup.
tools.result=#Result
tools.run=#Run
tools.run=Выполнить
tools.runScript=#RunScript
tools.runScript.help=#Runs a SQL script.
tools.script=#Script
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Príklad SQL skriptu
helpStatements=SQL príkazy
helpUpdate=Zmeniť dáta v riadku
helpWithColumnsIdName=so stĺpcami ID a NAME
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Pripojiť
login.driverClass=Trieda ovládača
login.driverNotFound=Databázový ovládač nebol nájdený<br />Použite pomocníka na zistenie, ako pridať databázový ovládač
......@@ -101,8 +106,8 @@ toolbar.history=História príkazov
toolbar.maxRows=Max. riadkov
toolbar.refresh=Obnoviť
toolbar.rollback=Rollback (odvolať)
toolbar.run=Spustiť (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Spustiť
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=SQL príkaz
tools.backup=Zálohovať
tools.backup.help=Vytvorenie zálohy databázy
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Örnek SQL
helpStatements=SQL komutları
helpUpdate=Bir tabeladaki belli bir satır içeriğini değiştirir
helpWithColumnsIdName=Colon isimleriyle birlikte
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Bağlan
login.driverClass=Veri tabanı sürücü sınıfı
login.driverNotFound=İstenilen veri tabanı sürücüsü bulunamadı<br />Sürücü ekleme konusunda bilgi için Yardım'a başvurunuz
......@@ -102,7 +107,7 @@ toolbar.maxRows=Maximum dizi sayısı
toolbar.refresh=Güncelleştir
toolbar.rollback=Değişiklikleri geri al
toolbar.run=İşlemi yürüt
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=SQL komutu
tools.backup=Yedekle
tools.backup.help=Bir veritabanının yedeklemesini yapar.
......
......@@ -55,6 +55,11 @@ helpSampleSQL=Приклад SQL запиту
helpStatements=SQL запити
helpUpdate=Змінити дані в рядку
helpWithColumnsIdName=з колонками ID і NAME
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=Під'єднатись
login.driverClass=Driver Class
login.driverNotFound=Дравер бази даних не знайдено<br />Подивіться в допомозі як додати нові драйвери
......@@ -101,8 +106,8 @@ toolbar.history=Iсторія команд
toolbar.maxRows=Максимальна кількість рядків
toolbar.refresh=Оновити
toolbar.rollback=Вернути назад
toolbar.run=Виконати (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=Виконати
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=SQL запит
tools.backup=#Backup
tools.backup.help=#Creates a backup of a database.
......@@ -126,7 +131,7 @@ tools.recover.help=#Helps recovering a corrupted database.
tools.restore=#Restore
tools.restore.help=#Restores a database backup.
tools.result=#Result
tools.run=#Run
tools.run=Виконати
tools.runScript=#RunScript
tools.runScript.help=#Runs a SQL script.
tools.script=#Script
......
......@@ -55,6 +55,11 @@ helpSampleSQL=样例SQL脚本
helpStatements=SQL 语句
helpUpdate=改变一行数据
helpWithColumnsIdName=用ID和NAME列
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=连接
login.driverClass=驱动类
login.driverNotFound=找不到数据库驱动<br />请参考帮助去添加数据库驱动
......@@ -101,8 +106,8 @@ toolbar.history=历史SQL命令
toolbar.maxRows=最大行数
toolbar.refresh=刷新
toolbar.rollback=回滚
toolbar.run=执行 (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=执行
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=SQL 语句
tools.backup=备份
tools.backup.help=创建一个数据库备份
......
......@@ -55,6 +55,11 @@ helpSampleSQL=範例SQL腳本
helpStatements=SQL述句
helpUpdate=變更資料列 (row) 中的資料
helpWithColumnsIdName=用ID和NAME欄位
key.alt=#Alt
key.ctrl=#Ctrl
key.enter=#Enter
key.shift=#Shift
key.space=#Space
login.connect=連接
login.driverClass=驅動程式類別 (Driver Class)
login.driverNotFound=沒有找到資料庫驅動程式<br />請參考輔助說明來添加驅動程式
......@@ -101,8 +106,8 @@ toolbar.history=命令史
toolbar.maxRows=最大資料列 (rows)
toolbar.refresh=更新
toolbar.rollback=退返 (rollback)
toolbar.run=執行 (Ctrl+Enter)
toolbar.runSelected=#Run Selected (Shift+Enter)
toolbar.run=執行
toolbar.runSelected=#Run Selected
toolbar.sqlStatement=SQL 述句
tools.backup=備份
tools.backup.help=建立資料庫的備份
......
......@@ -121,10 +121,10 @@ Initial Developer: H2 Group
${text.toolbar.autoComplete}&nbsp;
<select name="autoComplete" size="1"
onchange="javascript:top.frames['h2query'].setAutoComplete(this.value)">
<option value="0">
<option selected="selected" value="0">
${text.toolbar.autoComplete.off}
</option>
<option selected="selected" value="1">
<option value="1">
${text.toolbar.autoComplete.normal}
</option>
<option value="2">
......
......@@ -28,34 +28,35 @@ function set(s) {
<table>
<tr>
<td style="padding:0px"><img src="icon_help.gif" alt="${text.a.help}"/></td>
<td style="vertical-align: middle;">
${text.helpDisplayThis}
</td>
<td style="vertical-align: middle;"></td>
<td style="vertical-align: middle;">${text.helpDisplayThis}</td>
</tr>
<tr>
<td style="padding:0px"><img src="icon_history.gif" alt="${text.toolbar.history}"/></td>
<td style="vertical-align: middle;">
${text.helpCommandHistory}
</td>
<td style="vertical-align: middle;"></td>
<td style="vertical-align: middle;">${text.helpCommandHistory}</td>
</tr>
<tr>
<td style="padding:0px"><img src="icon_run_selected.gif" alt="${text.toolbar.run}"/></td>
<td style="vertical-align: middle;">
${text.helpExecuteCurrent}
</td>
<td style="padding:0px"><img src="icon_run.gif" alt="${text.toolbar.run}"/></td>
<td style="vertical-align: middle;">${text.key.ctrl}+${text.key.enter}</td>
<td style="vertical-align: middle;">${text.helpExecuteCurrent}</td>
</tr>
<tr>
<td style="padding:0px"><img src="icon_run.gif" alt="${text.toolbar.runSelected}"/></td>
<td style="vertical-align: middle;">
${text.helpExecuteSelected}
</td>
<td style="padding:0px"><img src="icon_run_selected.gif" alt="${text.toolbar.runSelected}"/></td>
<td style="vertical-align: middle;">${text.key.shift}+${text.key.enter}</td>
<td style="vertical-align: middle;">${text.helpExecuteSelected}</td>
</tr>
<tr>
<td style="padding:0px"></td>
<td style="vertical-align: middle;">${text.key.ctrl}+${text.key.space}</td>
<td style="vertical-align: middle;">${text.toolbar.autoComplete}</td>
</tr>
<tr>
<td style="padding:0px"><img src="icon_disconnect.gif" alt="${text.toolbar.disconnect}"/></td>
<td style="vertical-align: middle;">
${text.helpDisconnect}
</td>
<td style="vertical-align: middle;"></td>
<td style="vertical-align: middle;">${text.helpDisconnect}</td>
</tr>
</table>
<h3>${text.helpSampleSQL}</h3>
......
......@@ -16,7 +16,7 @@ Initial Developer: H2 Group
var agent=navigator.userAgent.toLowerCase();
var is_opera = agent.indexOf("opera") >= 0;
var autoComplete = 1; // 0: off, 1: normal, 2: full
var autoComplete = 0; // 0: off, 1: normal, 2: full
var selectedRow = -1;
var lastList = '';
var lastQuery = null;
......@@ -212,10 +212,7 @@ function keyDown(event) {
return false;
} else if (key == 32 && (event.ctrlKey || event.altKey)) {
// ctrl + space
autoCompleteManual = true;
lastQuery = null;
lastList = '';
showAutoCompleteNow();
manualAutoComplete();
return false;
} else if (key == 190 && autoComplete == 0) {
// dot
......@@ -231,16 +228,14 @@ function keyDown(event) {
}
showOutput('');
return false;
} else if (key == 9 && !event.shiftKey) {
} else if ((key == 9 && !event.shiftKey) || (key == 13 && !event.shiftKey && !event.ctrlKey && !event.altKey)) {
// tab
if (table.rows.length > selectedRow) {
var row = table.rows[selectedRow];
if (row.cells.length>1) {
insertText(row.cells[1].innerHTML);
}
if (autoComplete == 0) {
setAutoComplete(0);
}
removeAutoComplete();
return false;
}
} else if (key == 38 && !event.shiftKey) {
......@@ -248,15 +243,22 @@ function keyDown(event) {
if (table.rows.length > selectedRow) {
selectedRow = selectedRow <= 0 ? table.rows.length-1 : selectedRow-1;
highlightRow(selectedRow);
return false;
}
return false;
} else if (key == 40 && !event.shiftKey) {
// down
if (table.rows.length > selectedRow) {
selectedRow = selectedRow >= table.rows.length-1 ? 0 : selectedRow+1;
highlightRow(selectedRow);
return false;
}
return false;
}
if (autoComplete == 0) {
// remove auto-complete if manually started
while (table.rows.length > 0) {
table.deleteRow(0);
}
showOutput('');
}
}
// alert('key:' + key);
......@@ -285,19 +287,30 @@ function keyUp(event) {
function setAutoComplete(value) {
autoComplete = value;
if (value != 1) {
if (value == 0) {
removeAutoComplete();
} else {
var s = lastList;
lastList = '';
showList(s);
} else {
var table = getAutoCompleteTable();
while (table.rows.length > 0) {
table.deleteRow(0);
}
showOutput('');
}
}
function manualAutoComplete() {
autoCompleteManual = true;
lastQuery = null;
lastList = '';
showAutoCompleteNow();
}
function removeAutoComplete() {
var table = getAutoCompleteTable();
while (table.rows.length > 0) {
table.deleteRow(0);
}
showOutput('');
}
function highlightRow(row) {
if (row != null) {
selectedRow = row;
......@@ -342,9 +355,6 @@ function showList(s) {
while (table.rows.length > 0) {
table.deleteRow(0);
}
if (autoComplete==0) {
return;
}
selectedRow = 0;
var count = 0;
var doc = top.h2result.document;
......@@ -482,6 +492,7 @@ function submitSelected() {
<span style="white-space:nowrap">
<input type="button" class="button" value="${text.toolbar.run}" onclick="javascript:submitAll();sql.focus();return true;" />
<input type="button" class="button" value="${text.toolbar.runSelected}" onclick="javascript:submitSelected();sql.focus();return true;" />
<input type="button" class="button" value="${text.toolbar.autoComplete}" onclick="javascript:manualAutoComplete();sql.focus();return true;" />
<input type="button" class="button" value="${text.toolbar.clear}" onclick="javascript:sql.value='';keyUp();sql.focus();return true;" />
${text.toolbar.sqlStatement}:
</span>
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论