--- loncom/interface/londocs.pm 2012/05/07 02:19:44 1.484.2.1 +++ loncom/interface/londocs.pm 2012/05/13 22:59:39 1.484.2.4 @@ -1,7 +1,7 @@ # The LearningOnline Network # Documents # -# $Id: londocs.pm,v 1.484.2.1 2012/05/07 02:19:44 raeburn Exp $ +# $Id: londocs.pm,v 1.484.2.4 2012/05/13 22:59:39 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1664,7 +1664,7 @@ sub checkonthis { =item list_symbs() -List Content Idenifiers +List Content Identifiers =cut @@ -2440,9 +2440,9 @@ sub handler { $script .= &editing_js($udom,$uname,$supplementalflag). &history_tab_js(). &inject_data_js(). - &resize_contentdiv_js($tabidstr); + &Apache::lonhtmlcommon::resize_scrollbox_js('docs',$tabidstr); $addentries = { - onload => "javascript:resize_contentdiv('contentscroll','1','1');", + onload => "javascript:resize_scrollbox('contentscroll','1','1');", }; } } @@ -2540,7 +2540,7 @@ sub handler { 'upld' => 'Import Document', 'srch' => 'Search', 'impo' => 'Import', - 'wish' => 'Import from Wishlist', + 'book' => 'Import Bookmarks', 'selm' => 'Select Map', 'load' => 'Load Map', 'reco' => 'Recover Deleted Documents', @@ -2608,7 +2608,7 @@ SEDFFORM my @simpleeditdefaultforma = ( { ''.$lt{srch}.'' => "$uploadtag$lt{'srch'}" }, { ''.$lt{impo}.'' => "$lt{'impo'}$help{'Importing_LON-CAPA_Resource'}" }, - { ''.$lt{wish}.'' => "$lt{'wish'}" }, + { ''.$lt{book}.'' => "$lt{'book'}" }, ); $simpleeditdefaultform .= &create_form_ul(&create_list_elements(@simpleeditdefaultforma)); $simpleeditdefaultform .=(<'.$backtext.''."\n"; if ($tid == 1) { $form .= '
  • '. - ''. + ''. &mt('Undo Delete').'
  • '."\n"; if ($env{'form.docslog'}) { $form .= '
  • '; @@ -3682,7 +3682,7 @@ function showPage(current, pageId, nav, } } } - resize_contentdiv('contentscroll','1','0'); + resize_scrollbox('contentscroll','1','0'); return false; } @@ -3799,196 +3799,6 @@ function choose_switchserver_window() { ENDSWITCHJS } -sub resize_contentdiv_js { - my ($tabidstr) = @_; - my $viewport_js = &Apache::loncommon::viewport_geometry_js(); - return < maxtabw) { - maxtabw = actabw; - } - } else { - if (document.getElementById(alltabs[i]) != null) { - var thistab = document.getElementById(alltabs[i]); - thistab.style.visibility = 'hidden'; - thistab.style.display = 'block'; - var tabw = document.getElementById(alltabs[i]).offsetWidth; - thistab.style.display = 'none'; - thistab.style.visibility = ''; - if (tabw > maxtabw) { - maxtabw = tabw; - } - } - } - } - - if (maxtabw > 0) { - var newscrollboxw; - if (maxtabw+paddingw+scrollboxscrollw scrollboxheight) { - if (freevspace > offsetv) { - newscrollboxheight = scrollboxheight+freevspace-offsetv; - if (newscrollboxheight < minvscrollbox) { - newscrollboxheight = minvscrollbox; - } - scrollbox.style.height = newscrollboxheight+"px"; - } - } - } - scrollboxheight = scrollbox.offsetHeight; - var contentlistheight = document.getElementById("contentlist").offsetHeight; - - if (scrollboxscrollheight <= scrollboxheight) { - if ((contentlistheight+offsetv)