mirror of
https://github.com/logicog/RTLPlayground.git
synced 2026-08-30 14:52:51 +08:00
l2: sort and filter the forwarding table from its header
The table lists every learned and static entry in one flat block, which is fine with a handful and unusable with a few hundred: finding out where one MAC sits, or what a port has learned, meant reading the whole thing. Make the column headings sort and give each one a filter box. Filters are substring matches combined with AND, so "port 8 + static" is two keystrokes. A counter above the table shows matched out of total, so a filter that hides everything is obvious rather than looking like an empty table. Sorting keeps the CPU entry from comparing as a number - it sorts last instead of landing between ports 8 and 9, where a string-vs-number compare would otherwise put it. The filter inputs live inside the existing header cells rather than in a second row: the paint loop addresses data rows as rows[i+1], and a second header row would have shifted every one of them.
This commit is contained in:
@@ -117,6 +117,7 @@ var LANG = {
|
||||
l2_col_port: 'Port',
|
||||
l2_col_type: 'Type',
|
||||
l2_col_remove: 'Remove Entry',
|
||||
l2_shown: 'Shown:',
|
||||
l2_delete: 'Delete',
|
||||
l2_static: 'static',
|
||||
l2_learned: 'learned',
|
||||
@@ -296,6 +297,7 @@ var LANG = {
|
||||
l2_col_port: 'ポート',
|
||||
l2_col_type: 'タイプ',
|
||||
l2_col_remove: 'エントリ削除',
|
||||
l2_shown: 'Shown:',
|
||||
l2_delete: '削除',
|
||||
l2_static: '静的',
|
||||
l2_learned: '学習',
|
||||
@@ -475,6 +477,7 @@ var LANG = {
|
||||
l2_col_port: '端口',
|
||||
l2_col_type: '类型',
|
||||
l2_col_remove: '删除条目',
|
||||
l2_shown: 'Shown:',
|
||||
l2_delete: '删除',
|
||||
l2_static: '静态',
|
||||
l2_learned: '动态学习',
|
||||
|
||||
Reference in New Issue
Block a user