İ found my mistake: when i use gnomevfs.async.get_file_info in the button on_click event that open a filedialog at the remote host, it worked fine. I have a line like: filedialog2.filechooserdialog2.set_current_folder_uri(uri) in the same funciton i used the gnomevfs.async.get_file_info(). So what i learned is, if i close the filechooserdialog, and trying use an url like ([EMAIL PROTECTED]/path) doesnt work for get_file_info :)
Sı it seems when it is closed, the connection is also closed. On 7/18/05, Gustavo J. A. M. Carneiro <[EMAIL PROTECTED]> wrote: > On Mon, 2005-07-18 at 11:24 +0300, Ogz wrote: > > Here is my code: > > > > def fileinfo_callback(handle, results): > > for uri, exc_type, info in results: > > print uri > > print info > > Can you print exc_type? Maybe there was an error? > > > if not exc_type: > > try: > > print info.size > > except ValueError: > > pass > > > > > > this function is defined abeve the main Window class, so it is global. > > > > In the main window, which is created by tepache using glade i am > > using a code for a button's on_click event > > > > uri = server + "/" + self.Txt_add.get_text() > > gnomevfs.async.get_file_info(uri,fileinfo_callback, options = > > gnomevfs.FILE_INFO_DEFAULT) > > > > and here is the output: > > > > file:[EMAIL PROTECTED]:22/home/oguz/identity.pub > > <gnomevfs.FileInfo '(null)'> > > > > so i can not get the size of the file. I dont know what the problem > > is, if you help i will be happy. > > _______________________________________________ > > pygtk mailing list [email protected] > > http://www.daa.com.au/mailman/listinfo/pygtk > > Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/ > -- > Gustavo J. A. M. Carneiro > <[EMAIL PROTECTED]> <[EMAIL PROTECTED]> > The universe is always one step beyond logic. > > >
_______________________________________________ pygtk mailing list [email protected] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
