Changeset 183 for trunk/desktop/class_c
- Timestamp:
- Jan 7, 2007, 10:36:52 PM (19 years ago)
- Location:
- trunk/desktop/class_c
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/desktop/class_c/wpfilesystem.c
r146 r183 43 43 44 44 #include <string.h> 45 #include "gtk/gtk.h" 46 /* Gui stuff */ 47 #include "nomguitk.h" 48 #include "nomwindow.h" 49 #include "desktoptypes.h" 50 51 #include "nomfolderwindow.h" 52 53 45 54 #include "wpfilesystem.ih" 46 55 … … 54 63 } 55 64 56 NOM_Scope PNOMPath NOMLINK impl_WPFileSystem_wpQuery RealName(WPFileSystem* nomSelf, const CORBA_boolean bFullPath,65 NOM_Scope PNOMPath NOMLINK impl_WPFileSystem_wpQueryFileName(WPFileSystem* nomSelf, const CORBA_boolean bFullPath, 57 66 CORBA_Environment *ev) 58 67 { 59 68 WPFileSystemData* nomThis=WPFileSystemGetData(nomSelf); 60 PNOMPath nomRetval =NOMPathNew();61 62 NOMPath_assignCString(nomRetval, _pszFullPath, ev);69 PNOMPath nomRetval; 70 PNOMPath nomPath; 71 PWPFolder wpParent; 63 72 64 return nomRetval; 73 if(!bFullPath){ 74 nomRetval=NOMPathNew(); 75 return (PNOMPath) NOMPath_assignCString(nomRetval, _pszFullPath, ev); 76 } 77 78 /* we are interested in the full path */ 79 80 /* Get parent folder */ 81 wpParent=WPFileSystem_wpQueryFolder(nomSelf, NULLHANDLE); 82 83 if(NULLHANDLE==wpParent) 84 { 85 /* We are root folder */ 86 nomRetval=NOMPathNew(); 87 return (PNOMPath) NOMPath_assignCString(nomRetval, _pszFullPath, ev); 88 } 89 90 /* We area folder somwhere in the chain */ 91 nomRetval=WPFileSystem_wpQueryFileName((WPFileSystem*)wpParent, bFullPath, NULLHANDLE); 92 nomPath=NOMPathNew(); 93 nomPath= (PNOMPath) NOMPath_assignCString(nomPath, _pszFullPath, ev); 94 95 return (PNOMPath)NOMPath_appendPath(nomRetval, nomPath, NULLHANDLE); 65 96 } 66 97 -
trunk/desktop/class_c/wpfolder.c
r172 r183 59 59 /* Gui stuff */ 60 60 #include "nomguitk.h" 61 #include "nomwindow.h" 62 #include "desktoptypes.h" 63 61 64 #include "nomfolderwindow.h" 62 65 … … 65 68 #include "desktop.h" 66 69 #include "helper.h" 67 #include "desktoptypes.h" 70 68 71 69 72 … … 249 252 250 253 #warning !!!!! Path taken from a test location !!!!! 251 WPFolder_wpPopulate(nomSelf, 0L, NOMPath_ getCString(WPFolder_wpQueryRealName(nomSelf, TRUE, ev) , ev), FALSE, ev);254 WPFolder_wpPopulate(nomSelf, 0L, NOMPath_queryCString(WPFolder_wpQueryFileName(nomSelf, TRUE, ev) , ev), FALSE, ev); 252 255 break; 253 256 -
trunk/desktop/class_c/wpobject.c
r176 r183 61 61 #endif 62 62 63 #ifndef WPFolder 64 typedef struct WPFolder_struct { 65 struct nomMethodTabStruct *mtab; 66 gulong body[1]; 67 } WPFolderObj; 68 #define WPFolder WPFolderObj 69 typedef WPFolder *PWPFolder; 70 #endif 71 63 72 #include "nomwindow.h" 64 73 #include "desktoptypes.h" … … 186 195 187 196 g_return_val_if_fail(NULLHANDLE!=wpObject, FALSE); 197 198 WPObject_wpSaveDeferred(wpObject, NULLHANDLE); 188 199 189 200 WPObject_wpDeleteFromObjUseList(wpObject, pUseItem, NULLHANDLE); … … 445 456 446 457 /* Create a new title */ 447 NOMString_assign String(tmpString, pnomStrNewTitle, ev);458 NOMString_assign(tmpString, pnomStrNewTitle, ev); 448 459 449 460 /* It may happen that someone changed the title from another thread. We may either … … 472 483 tmpPtr=g_atomic_pointer_get(&_pnomStringTitle); 473 484 474 return NOMString_copy String(tmpPtr, ev);485 return NOMString_copy(tmpPtr, ev); 475 486 } 476 487 … … 656 667 } 657 668 658 659 660 669 NOM_Scope CORBA_boolean NOMLINK impl_WPObject_wpSaveDeferred(WPObject* nomSelf, CORBA_Environment *ev) 670 { 671 /* WPObjectData* nomThis=WPObjectGetData(nomSelf); */ 672 673 g_message("%s not implemented", __FUNCTION__); 674 675 return TRUE; 676 } 677 678 NOM_Scope CORBA_boolean NOMLINK impl_WPObject_wpSaveImmediate(WPObject* nomSelf, CORBA_Environment *ev) 679 { 680 /* WPObjectData* nomThis=WPObjectGetData(nomSelf); */ 681 682 g_message("%s not implemented", __FUNCTION__); 683 684 return TRUE; 685 } 686 687 NOM_Scope void NOMLINK impl_WPObject_wpSetFolder(WPObject* nomSelf, const PWPFolder wpParentFolder, 688 CORBA_Environment *ev) 689 { 690 WPObjectData* nomThis=WPObjectGetData(nomSelf); 691 692 _wpParentFldr=wpParentFolder; 693 } 694 695 NOM_Scope PWPFolder NOMLINK impl_WPObject_wpQueryFolder(WPObject* nomSelf, CORBA_Environment *ev) 696 { 697 WPObjectData* nomThis=WPObjectGetData(nomSelf); 698 699 return _wpParentFldr; 700 } 701
Note:
See TracChangeset
for help on using the changeset viewer.