2.5: File browser
[blender.git] / source / blender / editors / space_text / text_ops.c
index 79912d9ed0ef8ece1a2cb6a8a0dbfff3c6fd0bb9..4c9f47ed170e1b1e5ed55ef67a9443f7fd74a633 100644 (file)
@@ -231,7 +231,7 @@ void TEXT_OT_open(wmOperatorType *ot)
        ot->poll= text_new_poll;
 
        /* properties */
-       RNA_def_string_file_path(ot->srna, "filename", "", FILE_MAX, "Filename", "File path of image to open.");
+       WM_operator_properties_filesel(ot, FOLDERFILE|TEXTFILE|PYSCRIPTFILE);
 }
 
 /******************* reload operator *********************/
@@ -498,7 +498,7 @@ void TEXT_OT_save_as(wmOperatorType *ot)
        ot->poll= text_edit_poll;
 
        /* properties */
-       RNA_def_string_file_path(ot->srna, "filename", "", FILE_MAX, "Filename", "File path to save image to.");
+       WM_operator_properties_filesel(ot, FOLDERFILE|TEXTFILE|PYSCRIPTFILE);
 }
 
 /******************* run script operator *********************/