📄 typeitem.java
字号:
// Decompiled by Jad v1.5.8e2. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://kpdus.tripod.com/jad.html
// Decompiler options: packimports(3) fieldsfirst ansi space
// Source File Name: TypeItem.java
package org.gudy.azureus2.ui.swt.views.tableitems.myshares;
import org.gudy.azureus2.core3.internat.MessageText;
import org.gudy.azureus2.plugins.sharing.ShareResource;
import org.gudy.azureus2.plugins.sharing.ShareResourceDirContents;
import org.gudy.azureus2.plugins.ui.tables.TableCell;
import org.gudy.azureus2.plugins.ui.tables.TableCellRefreshListener;
import org.gudy.azureus2.ui.swt.views.table.utils.CoreTableColumn;
public class TypeItem extends CoreTableColumn
implements TableCellRefreshListener
{
public TypeItem()
{
super("type", -2, 100, "MyShares");
}
public void refresh(TableCell cell)
{
ShareResource item = (ShareResource)cell.getDataSource();
String text = "";
if (item != null)
{
int type = item.getType();
if (!cell.setSortValue(type) && cell.isValid())
return;
if (type == 2)
text = MessageText.getString("MySharesView.type.dir");
else
if (type == 1)
text = MessageText.getString("MySharesView.type.file");
else
if (type == 3)
{
ShareResourceDirContents s = (ShareResourceDirContents)item;
if (s.isRecursive())
text = MessageText.getString("MySharesView.type.dircontentsrecursive");
else
text = MessageText.getString("MySharesView.type.dircontents");
}
}
cell.setText(text);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -