WorkbenchAdvisor中的方法执行顺序

  1. initialize - called first; before any windows; use to register things
  2. preStartup - called second; after initialize but before first window is opened; use to temporarily disable things during startup or restore
  3. postStartup - called third; after first window is opened; use to reenable things temporarily disabled in previous step
  4. postRestore - called after the workbench and its windows has been recreated from a previously saved state; use to adjust the restored workbench
  5. preWindowOpen - called as each window is being opened; use to configure aspects of the window other than actions bars
  6. fillActionBars - called after preWindowOpen to configure a window's action bars
  7. postWindowRestore - called after a window has been recreated from a previously saved state; use to adjust the restored window
  8. postWindowCreate - called after a window has been created, either from an initial state or from a restored state; used to adjust the window
  9. openIntro - called immediately before a window is opened in order to create the introduction component, if any.
  10. postWindowOpen - called after a window has been opened; use to hook window listeners, etc.
  11. preWindowShellClose - called when a window's shell is closed by the user; use to pre-screen window closings
  12. eventLoopException - called to handle the case where the event loop has crashed; use to inform the user that things are not well
  13. eventLoopIdle - called when there are currently no more events to be processed; use to perform other work or to yield until new events enter the queue
  14. preShutdown - called just after event loop has terminated but before any windows have been closed; use to deregister things registered during initialize
  15. postShutdown - called last; after event loop has terminated and all windows have been closed; use to deregister things registered during initialize

我的翻译,英文水平不咋地,对照英文凑服看看吧,呵呵。

  1. initialize – 在所有窗体之前最先调用,可用于注册实体。
  2. preStartup – 在initialize之后但在第一个打开窗体之前调用,可用于在启动或恢复时临时禁用实体。
  3. postStartup – 在preStartup之后但在第一个打开窗体之前调用,可用于重新启用上一步骤禁用的实体。
  4. postRestore – 在工作台的窗体从先前保存的状态中恢复后调用。可用于调整恢复的工作台。
  5. preWindowOpen – 在窗体打开之前调用,用于配置窗体的外貌除了工具条(菜单、工具条等)。
  6. fillActionBars – 在preWindowOpen后调用,用来配置窗体的工具条。
  7. postWindowRestore - 在窗体从先前保存的状态或从一个初始的状态中恢复后调用,用于调整窗体。
  8. postWindowCreate – 在窗体从一个初始的状态或从一个恢复的状态中创建后调用,用于调整窗体。
  9. openIntro – 打开窗体前调用,为了创建介绍组件。
  10. postWindowOpen – 在窗体打开后调用,可用于调用窗体监听器或其他。
  11. preWindowShellClose – 在窗体的Shell被用户关闭后调用,用来关闭屏幕窗体。
  12. eventLoopException – 当事件循环(Event Loop)崩溃时用来操作异常事件,用来通知用户出现问题了。
  13. eventLoopIdle – 当当前没有可以处理的事件时调用,用来执行其他工作或挂起直到新的时间进入了队列。
  14. preShutdown – 在事件循环终止后窗体被关闭前调用,用来注销在初始化时注册的实体。
  15. postShutdown –在事件循环终止且所有的窗体都被关闭后最后调用,用来注销在初始化时注册的实体。
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值