+bool
+wxMSWFileSystemWatcher::AddTree(const wxFileName& path,
+ int events,
+ const wxString& filter)
+{
+ if ( !filter.empty() )
+ {
+ // Use the inefficient generic version as we can only monitor
+ // everything under the given directory.
+ //
+ // Notice that it would probably be better to still monitor everything
+ // natively and filter out the changes we're not interested in.
+ return wxFileSystemWatcherBase::AddTree(path, events, filter);
+ }
+
+
+ if ( !path.DirExists() )
+ {
+ wxLogError(_("Can't monitor non-existent directory \"%s\" for changes."),
+ path.GetFullPath());
+ return false;
+ }
+
+ return DoAdd(path, events, wxFSWPath_Tree);
+}
+