+ super();
+ addWindowListener(new MainFrameWindowListener());
+ setTitle(MainFrame_AboutBox.VERSION);
+
+ final Config p = Config.INSTANCE;
+
+ // ワーカスレッド生成
+ final int thDownload = p.getSystemDownloadThread();
+ final int secDownload = p.getSystemDownloadWait();
+ final int thConvert = p.getSystemConvertThread();
+ taskManager = new TaskManage(thDownload, secDownload, thConvert, new GuiTaskManageListener());
+
+ // ディレクトリ監視スレッド生成
+ final FileSystem fs = FileSystems.getDefault();
+
+ final List<String> videoSearchDirs = p.getSearchVideoDirs();
+ videoSearchDirs.add(p.getVideoDir());
+ final Set<Path> videoPaths = new HashSet<>(videoSearchDirs.size());
+ for (String s : videoSearchDirs) {
+ videoPaths.add(fs.getPath(s));
+ }
+ videoFileWatcher = new FileWatch(videoPaths);
+ this.videoFileWatcherThread = new Thread(videoFileWatcher);
+ this.videoFileWatcherThread.setDaemon(true);
+
+ final List<String> commentSearchDirs = p.getSearchCommentDirs();
+ commentSearchDirs.add(p.getCommentDir());
+ final Set<Path> commentPaths = new HashSet<>(commentSearchDirs.size());
+ for(String s : commentSearchDirs) {
+ commentPaths.add(fs.getPath(s));
+ }
+ commentFileWatcher = new FileWatch(commentPaths);
+ this.commentFileWatcherThread = new Thread(commentFileWatcher);
+ this.commentFileWatcherThread.setDaemon(true);
+