CounterDetailViewer.java 文件源码

java
阅读 29 收藏 0 点赞 0 评论 0

项目:VASSAL-src 作者:
public void addTo(Buildable b) {
  map = (Map) b;
  view = map.getView();
  validator = new SingleChildInstance(map, getClass());
  map.addDrawComponent(this);
  String keyDesc = hotkey == null ? "" : "(" + HotKeyConfigurer.getString(hotkey) + ")";
  GameModule.getGameModule().getPrefs().addOption(Resources.getString("Prefs.general_tab"),
      new BooleanConfigurer(USE_KEYBOARD, Resources.getString("CounterDetailViewer.use_prompt", keyDesc), Boolean.FALSE));
  GameModule.getGameModule().getPrefs().addOption(Resources.getString("Prefs.general_tab"),
      new IntConfigurer(PREFERRED_DELAY, Resources.getString("CounterDetailViewer.delay_prompt"), delay));

  view.addMouseMotionListener(this);
  view.addMouseListener(this);
  view.addKeyListener(this);
  DragSource.getDefaultDragSource().addDragSourceMotionListener(this);

  setAttributeTranslatable(VERSION, false);
  setAttributeTranslatable(SUMMARY_REPORT_FORMAT, true);
  setAttributeTranslatable(COUNTER_REPORT_FORMAT, true);
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号