-$inlineremote[21] $inlineremote[23]
-ENDARROWSINLINE
- if (&hidden_button_check() ne 'yes') {
- $inlinebuttons .= (<
-ENDINLINEICONS
- }
+ foreach (@inlineremote) { if ($_ ne '') { $addremote=1; last;} }
+ if ($addremote) {
+
+ &Apache::lonhtmlcommon::clear_breadcrumb_tools();
+
+ &Apache::lonhtmlcommon::add_breadcrumb_tool(
+ 'navigation', @inlineremote[21,23]);
+
+ my $countdown = &countdown_timer();
+ if (&hidden_button_check() eq 'yes') {
+ if ($countdown) {
+ &Apache::lonhtmlcommon::add_breadcrumb_tool('tools',$countdown);
+ }
+ } else {
+ my @tools = @inlineremote[93,91,81,82,83];
+ if ($countdown) {
+ unshift(@tools,$countdown);
+ }
+ &Apache::lonhtmlcommon::add_breadcrumb_tool(
+ 'tools',@tools);
+
+ #publish button in construction space
+ if ($env{'request.state'} eq 'construct'){
+ &Apache::lonhtmlcommon::add_breadcrumb_tool(
+ 'advtools', $inlineremote[63]);
} else {
- if ($inlineremote[21] ne '' || $inlineremote[23] ne '') {
- $inlinebuttons=(<$inlineremote[21] | | $inlineremote[23] |
-ENDFIRSTLINE
- }
- if (&hidden_button_check() ne 'yes') {
- foreach my $row (6..9) {
- if ($inlineremote[${row}.'1'] ne ''
- || $inlineremote[$row.'2'] ne ''
- || $inlineremote[$row.'3'] ne '') {
- $inlinebuttons .= <<"ENDLINE";
-$inlineremote["${row}1"] | $inlineremote["${row}2"] | $inlineremote["${row}3"] |
-ENDLINE
- }
- }
- }
- }
- }
- }
- $result =(<
-// BEGIN LON-CAPA Internal
-
-$timesync
-$tablestart
-$inlinebuttons
-$tableend
-$newmail
-
+ &Apache::lonhtmlcommon::add_breadcrumb_tool(
+ 'tools', $inlineremote[63]);
+ }
+ &advtools_crumbs(@inlineremote);
+ }
+ }
+ return &Apache::lonhtmlcommon::scripttag('', 'start')
+ . &Apache::lonhtmlcommon::breadcrumbs(undef,undef,0)
+ . &Apache::lonhtmlcommon::scripttag('', 'end');
-ENDREGTEXT
-# Registered, graphical output
} else {
- my $requri=&Apache::lonnet::clutter(&Apache::lonnet::fixversion((split(/\?/,$env{'request.noversionuri'}))[0]));
- $requri=&Apache::lonenc::check_encrypt(&unescape($requri));
- my $cursymb=&Apache::lonenc::check_encrypt($env{'request.symb'});
- my $navstatus=&get_nav_status();
- my $clearcstr;
-
- if ($env{'user.adv'}) { $clearcstr='clearbut(6,1)'; }
- $result = (<
+//
+
+$cstrcrumbs
ENDREGTHIS
}
-# =============================================================================
} else {
-# ========================================== This can or will not be registered
- if ($textual) {
-# Not registered, textual
- $result= (<
+//
ENDDONOTREGTHIS
- }
-# =============================================================================
+
+ }
+ return '';
}
- return $result;
}
-sub is_course_upload {
- my ($file,$cnum,$cdom) = @_;
- my $uploadpath = &LONCAPA::propath($cdom,$cnum);
- $uploadpath =~ s{^\/}{};
- if (($file =~ m{^\Q$uploadpath\E/userfiles/docs/}) ||
- ($file =~ m{^userfiles/\Q$cdom\E/\Q$cnum\E/docs/})) {
- return 1;
- }
- return;
+sub get_inline_text {
+ my %text = (
+ pgrd => 'Content Grades',
+ subm => 'Content Submissions',
+ pparm => 'Content Settings',
+ docs => 'Folder/Page Content',
+ pcstr => 'Edit',
+ prt => 'Print',
+ alnk => 'Stored Links',
+ anot => 'Notes',
+ catalog => 'Info',
+ eval => 'Evaluate',
+ fdbk => 'Feedback',
+ );
+ return %text;
}
-sub edit_course_upload {
- my ($file,$cnum,$cdom) = @_;
- my $cfile;
- if ($file =~/\.(htm|html|css|js|txt)$/) {
- my $ext = $1;
- my $url = &Apache::lonnet::hreflocation('',$file);
- my $home = &Apache::lonnet::homeserver($cnum,$cdom);
- my @ids=&Apache::lonnet::current_machine_ids();
- my $dest;
- if ($home && grep(/^\Q$home\E$/,@ids)) {
- $dest = $url.'?forceedit=1';
- } else {
- unless (&Apache::lonnet::get_locks()) {
- $dest = '/adm/switchserver?otherserver='.
- $home.'&role='.$env{'request.role'}.
- '&url='.$url.'&forceedit=1';
- }
- }
- if ($dest) {
- $cfile = &HTML::Entities::encode($dest,'"<>&');
- }
- }
- return $cfile;
+sub get_rc_text {
+ my %text = (
+ pgrd => 'problem[_1]',
+ subm => 'view sub-[_1]',
+ pparm => 'problem[_2]',
+ pcstr => 'edit[_1]',
+ prt => 'prepare[_1]',
+ back => 'backward[_1]',
+ forw => 'forward[_1]',
+ alnk => 'add to[_1]',
+ anot => 'anno-[_1]',
+ catalog => 'catalog[_2]',
+ eval => 'evaluate[_1]',
+ fdbk => 'feedback[_1]',
+ );
+ return %text;
}
sub loadevents() {
if ($env{'request.state'} eq 'construct' ||
- $env{'request.noversionuri'} =~ m{^/res/adm/pages/}) { return ''; }
+ $env{'request.noversionuri'} =~ m{^/res/adm/pages/}) { return ''; }
return 'LONCAPAreg();';
}
sub unloadevents() {
if ($env{'request.state'} eq 'construct' ||
- $env{'request.noversionuri'} =~ m{^/res/adm/pages/}) { return ''; }
+ $env{'request.noversionuri'} =~ m{^/res/adm/pages/}) { return ''; }
return 'LONCAPAstale();';
}
-
sub startupremote {
my ($lowerurl)=@_;
- if (($env{'browser.interface'} eq 'textual') ||
- ($env{'environment.remote'} eq 'off')) {
- return ('');
+ unless ($env{'environment.remote'} eq 'on') {
+ return ('');
}
#
# The Remote actually gets launched!
@@ -895,28 +1049,29 @@ sub startupremote {
my $message=&mt('"Waiting for Remote Control window to load: "+[_1]','waited');
return(<
+//
ENDREMOTESTARTUP
}
@@ -952,18 +1108,21 @@ ENDREMOTESTARTUP
sub setflags() {
return(<
+//
ENDSETFLAGS
}
sub maincall() {
- if (($env{'browser.interface'} eq 'textual') ||
- ($env{'environment.remote'} eq 'off')) { return ''; }
+ unless ($env{'environment.remote'} eq 'on') { return ''; }
return(<
+//
ENDMAINCALL
}
@@ -971,13 +1130,12 @@ ENDMAINCALL
sub load_remote_msg {
my ($lowerurl)=@_;
- if (($env{'browser.interface'} eq 'textual') ||
- ($env{'environment.remote'} eq 'off')) { return ''; }
+ unless ($env{'environment.remote'} eq 'on') { return ''; }
my $esclowerurl=&escape($lowerurl);
- my $link=&mt('[_1]Continue[_2] on in Inline Menu mode',
- '',
- '');
+ my $link=&mt('[_1]Continue[_2] on in Inline Menu mode'
+ ,''
+ ,'');
return(<
|