* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General
- * Public License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place, Suite 330,
- * Boston, MA 02111-1307, USA.
+ * Public License along with this library; if not, see <http://www.gnu.org/licenses/>.
*
* Author: Alexander Larsson <alexl@redhat.com>
*/
GFileMonitor*
_g_local_directory_monitor_new (const char *dirname,
- GFileMonitorFlags flags,
+ GFileMonitorFlags flags,
+ GMainContext *context,
gboolean is_remote_fs,
- GError **error)
+ gboolean do_start,
+ GError **error)
{
GFileMonitor *monitor = NULL;
GType type = G_TYPE_INVALID;
G_STRUCT_OFFSET (GLocalDirectoryMonitorClass, is_supported));
if (type != G_TYPE_INVALID)
- monitor = G_FILE_MONITOR (g_object_new (type, "dirname", dirname, "flags", flags, NULL));
+ monitor = G_FILE_MONITOR (g_object_new (type, "dirname", dirname, "flags", flags, "context", context, NULL));
else
g_set_error_literal (error, G_IO_ERROR, G_IO_ERROR_FAILED,
_("Unable to find default local directory monitor type"));
- if (monitor)
+ if (monitor && do_start)
g_local_directory_monitor_start (G_LOCAL_DIRECTORY_MONITOR (monitor));
return monitor;