|
|
|
@ -33,7 +33,7 @@ public class ProductNewsList extends JList<ProductNews> {
|
|
|
|
|
@Override |
|
|
|
|
public void mouseClicked(MouseEvent e) { |
|
|
|
|
if (e.getClickCount() == AlphaFineConstants.DEFAULT_CLICK_COUNT) { |
|
|
|
|
dealWithClick(); |
|
|
|
|
dealWithClick(getSelectedValue().getUrl()); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -62,17 +62,13 @@ public class ProductNewsList extends JList<ProductNews> {
|
|
|
|
|
this(new DefaultListModel<>()); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private void dealWithClick() { |
|
|
|
|
private void dealWithClick(String url) { |
|
|
|
|
ProductNews productNews = getSelectedValue(); |
|
|
|
|
jumpToUrl(productNews.getUrl()); |
|
|
|
|
BrowseUtils.browser(url); |
|
|
|
|
DesignerEnvManager.getEnvManager().getAlphaFineConfigManager().getReadSet().add(productNews.getId()); |
|
|
|
|
AlphaFineHelper.getAlphaFineDialog().repaint(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private void jumpToUrl(String url) { |
|
|
|
|
BrowseUtils.browser(url); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public int getHoverIndex() { |
|
|
|
|
return hoverIndex; |
|
|
|
|
} |
|
|
|
|