Changeset 1891
- Timestamp:
- 12/23/09 15:58:29 (14 years ago)
- Location:
- sandbox/filemanager
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
sandbox/filemanager/inc/class.user.inc.php
r1810 r1891 5 5 var $public_functions = array( 6 6 'save_preferences' => True, 7 'get_preferences' => True 7 'get_preferences' => True, 8 'card' => True 8 9 ); 9 10 … … 98 99 } 99 100 101 function card(){ 102 $account_info = $GLOBALS['phpgw']->accounts->get_list('accounts',0,1,1,base64_decode($this->lid),1,'lid'); 103 echo $account_info[0]['account_firstname'].' '.$account_info[0]['account_lastname']."<br>"; 104 echo $account_info[0]['account_email']; 105 /* 106 // TODO: PHOTO, ONLY FOR FOOL LDAP 107 if (isset($GLOBALS['phpgw_info']['server']['ldap_root_pw'])){ 108 } 109 */ 110 } 100 111 function get_preferences(){ 101 112 echo(serialize($_SESSION['phpgw_info']['user']['preferences']['filemanager'])); -
sandbox/filemanager/js/drag_area.js
r1872 r1891 11 11 12 12 document.onmousemove = function(event) { _dragArea.moveWindow(event); } 13 document.onmousedown = function(event) {_dragArea.pressed = 1; hide_ preview();};13 document.onmousedown = function(event) {_dragArea.pressed = 1; hide_card('preview');}; 14 14 document.onmouseup = function(event) { _dragArea.pressed = 0 }; 15 15 -
sandbox/filemanager/js/draw_api.js
r1889 r1891 251 251 retBuff += fl.td+'<img src="'+(file.icon)+'">'; 252 252 if((file.mime).toUpperCase().indexOf('IMAGE') == 0) 253 var mousefunc = 'draw_card(\' '+file.name+'\')'253 var mousefunc = 'draw_card(\'preview\',\''+file.name+'\')' 254 254 else 255 var mousefunc = 'hide_ preview()';255 var mousefunc = 'hide_card(\'preview\')'; 256 256 retBuff += '<a onmouseover="'+mousefunc+'" id="name_'+file.name+'" href="./index.php?menuaction=filemanager.uifilemanager.view&file='+base64_encode(file.name)+'&path='+base64_encode(currentPath)+'" target="_blank">'+file.name+'</a> </td>'; 257 257 if (preferences.mime_type =='1') retBuff += fl.td+file.mime+'</td>'; … … 287 287 retBuff += fl.td+dtString+'</td>'; 288 288 } 289 if (preferences.owner =='1') retBuff += fl.td+file.owner+'</td>'; 290 if (preferences.createdby_id =='1') retBuff += fl.td+file.creatdby+'</td>'; 291 if (preferences.modifiedby_id =='1') retBuff += fl.td+file.modifdby+'</td>'; 289 if (preferences.owner =='1'){ 290 retBuff += fl.td; 291 retBuff += '<div onmouseover="draw_card(\'user\',\''+file.owner+'\')">'+file.owner+'</div></td>'; 292 } 293 if (preferences.createdby_id =='1'){ 294 retBuff += fl.td; 295 retBuff += '<div onmouseover="draw_card(\'user\',\''+file.creatdby+'\')">'+file.creatdby+'</div></td>'; 296 } 297 if (preferences.modifiedby_id =='1'){ 298 retBuff += fl.td; 299 retBuff += '<div onmouseover="draw_card(\'user\',\''+file.modifdby+'\')">'+file.modifdby+'</div></td>'; 300 } 292 301 if (preferences.comment =='1') retBuff += fl.td+'<input id="'+file.name+'" class="inputComment" onkeydown="enterComments(event,this)" onclick="presetComments(this)" onblur="setComments(this)" value="'+(file.comm==null?'':file.comm)+'" alt="'+get_lang('Click to change comments')+'" title="'+get_lang('Click to change comments')+'"></input></td>'; 293 302 if (preferences.version =='1') retBuff += fl.td+'<span onclick="loadHistory(\''+file.name+'\')">'+file.vers+'</span></td>'; … … 585 594 } 586 595 587 function draw_card(filename){ 588 draw_window_card('preview','./index.php?menuaction=filemanager.vfs_functions.summary&file='+base64_encode(filename)+"&path="+base64_encode(currentPath)); 596 function draw_card(type,name){ 597 switch(type){ 598 case 'preview': 599 draw_window_card(type,'./index.php?menuaction=filemanager.vfs_functions.summary&file='+base64_encode(name)+"&path="+base64_encode(currentPath)); 600 break; 601 case 'user': 602 var hand = function (data) { draw_window_card('user',data); } 603 cExecute('./index.php?menuaction=filemanager.user.card&lid='+base64_encode(name),hand); 604 break; 605 default: 606 break; 607 } 589 608 } 590 609 function editFolders(operation){ … … 620 639 } 621 640 622 function draw_window_card(id, url){641 function draw_window_card(id,content){ 623 642 var menu = document.getElementById('menu_newFile'+id); 624 643 if (menu == null){ … … 629 648 menu.style.top = (DocY+20)+"px"; 630 649 menu.width = "100%"; 631 menu.innerHTML = '<img src="'+url+'">'; 632 menu.onmouseout = function () { menuTimeout = setTimeout("hide_preview()",50);} 650 menu.onmouseout = function () { menuTimeout = setTimeout("hide_card(\'"+id+"\')",50);} 633 651 menu.onmouseover = function () { clearTimeout(menuTimeout); }; 634 652 menu.style.zIndex='1'; … … 639 657 menu.style.left = DocX; 640 658 menu.style.top = (DocY+20)+"px"; 641 menu.innerHTML = '<img src="'+url+'">'; 642 } 659 } 660 if (id == 'preview') 661 menu.innerHTML = '<img src="'+content+'">'; 662 else 663 menu.innerHTML = content; 664 643 665 menu.style.visibility = 'visible'; 644 666 clearTimeout(menuTimeout); 645 menuTimeout = setTimeout("hide_ preview()",4000);646 } 647 function hide_ preview(){648 var e=document.getElementById('menu_newFile preview');667 menuTimeout = setTimeout("hide_card(\'"+id+"\')",4000); 668 } 669 function hide_card(id){ 670 var e=document.getElementById('menu_newFile'+id); 649 671 if (e!=null) 650 672 e.style.visibility = 'hidden';
Note: See TracChangeset
for help on using the changeset viewer.