Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/perseo22/pacmanager
Browse files Browse the repository at this point in the history
  • Loading branch information
hador committed Oct 9, 2016
2 parents 7948898 + 1a0803d commit 024bcb2
Show file tree
Hide file tree
Showing 7 changed files with 33 additions and 14 deletions.
2 changes: 1 addition & 1 deletion README
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@

- 4.5.5.8:

.
. Fixed a bug that prevented PAC from starting with "clusters" view selected

- 4.5.5.7:

Expand Down
6 changes: 5 additions & 1 deletion lib/PACMain.pm
Original file line number Diff line number Diff line change
Expand Up @@ -894,8 +894,12 @@ sub _initGUI {
$self -> _updateFavouritesList;
$self -> _updateGUIFavourites;
}
else {
elsif ( $$self{_CFG}{'defaults'}{'start PAC tree on'} eq 'history' ) {
$$self{_GUI}{nbTree} -> set_current_page( 2 );
$self -> _updateGUIClusters;
}
else {
$$self{_GUI}{nbTree} -> set_current_page( 3 );
$self -> _updateGUIHistory;
}

Expand Down
2 changes: 1 addition & 1 deletion lib/PACTerminal.pm
Original file line number Diff line number Diff line change
Expand Up @@ -1055,7 +1055,7 @@ sub _watchConnectionData {
$data = $self -> _checkSendKeystrokes( $data );

defined $$self{_EMBED_KIDNAP} and eval { Glib::Source -> remove( $$self{_EMBED_KIDNAP} ); };
$$self{_EMBED_KIDNAP} = Glib::Timeout -> add( 100, sub {
$$self{_EMBED_KIDNAP} = Glib::Timeout -> add( 500, sub {
my $title = 'FreeRDP: ' . $$self{_CFG}{environments}{$$self{_UUID}}{ip} . ( $$self{_CFG}{environments}{$$self{_UUID}}{port} == 3389 ? '' : ":$$self{_CFG}{environments}{$$self{_UUID}}{port}" );
$title = $$self{_CFG}{environments}{$$self{_UUID}}{method} eq 'RDP (xfreerdp)' ?
"FreeRDP: $$self{_CFG}{environments}{$$self{_UUID}}{ip}" . ( $$self{_CFG}{environments}{$$self{_UUID}}{port} == 3389 ? '' : ":$$self{_CFG}{environments}{$$self{_UUID}}{port}" ) :
Expand Down
15 changes: 12 additions & 3 deletions lib/PACUtils.pm
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,15 @@ my %WINDOWPROGRESS;
my $WIDGET_POPUP;

our @DONATORS_LIST = (
'Jeff Bakst',
'Sebastian Treu',
"Brian's Consultant Services",
'Cheah CH',
'Joseph Whipple',
'Felix Brack',
'Kalmykov Alexander',
'Paul Verreth',
'Iftimie Catalin Panaite',
'Andre Geißler',
'Arend de Boer',
'Taylor Finklea',
Expand Down Expand Up @@ -1843,7 +1852,7 @@ sub _cfgSanityCheck {
$$cfg{'defaults'}{'screenshots external viewer'} //= '/usr/bin/xdg-open';
$$cfg{'defaults'}{'screenshots use external viewer'}//= 0;
$$cfg{'defaults'}{'sort groups first'} //= 1;
$$cfg{'defaults'}{'word characters'} //= '\.:_\/-A-Za-z0-9';
$$cfg{'defaults'}{'word characters'} //= '\.:_\/a-zA-Z0-9-';
$$cfg{'defaults'}{'terminal emulation'} //= 'xterm';
$$cfg{'defaults'}{'show tray icon'} //= 1;
$$cfg{'defaults'}{'unsplit disconnected terminals'} //= 0;
Expand Down Expand Up @@ -3034,7 +3043,7 @@ sub _getXWindowsList {
$list{'by_pid'}{$data_pid}{'xid'} = $xid;
$list{'by_pid'}{$data_pid}{'command'} = $data_command;
}
}
}

#my $tw = Gtk2::Window -> new;
#my $vb = Gtk2::VBox -> new( 0, 0 );
Expand All @@ -3048,7 +3057,7 @@ sub _getXWindowsList {
#my $sock = Gtk2::Socket -> new;
#$vb -> add( $sock );
#$tw -> show_all;
#$sock -> add_id( $$list{'by_name'}{'Calculator'}{'xid'} );
#$sock -> add_id( $list{'by_name'}{'Calculator'}{'xid'} );

return \%list;
}
Expand Down
14 changes: 7 additions & 7 deletions lib/pac_conn
Original file line number Diff line number Diff line change
Expand Up @@ -665,13 +665,6 @@ sub _execScript {
$EXP -> clear_accum;
send_slow( $EXP, $txt );
};
$TERMINAL{get_prompt} = sub {
my $del_esq = shift // 1;
ctrl( "SCRIPT_SUB_GET_PROMPT[NAME:$name][PID:$$][PARAMS:]" );
my $prompt = _getPrompt();
$del_esq and $prompt = _removeEscapeSeqs( $prompt );
return "\Q$prompt\E";
};
$TERMINAL{send_get} = sub {
my $txt = shift // '';
my $intro = shift // 1;
Expand All @@ -683,6 +676,13 @@ sub _execScript {
$out =~ s/^.+?\R//go;
return _removeEscapeSeqs( $out );
};
$TERMINAL{get_prompt} = sub {
my $del_esq = shift // 1;
ctrl( "SCRIPT_SUB_GET_PROMPT[NAME:$name][PID:$$][PARAMS:]" );
my $prompt = _getPrompt();
$del_esq and $prompt = _removeEscapeSeqs( $prompt );
return "\Q$prompt\E";
};
$TERMINAL{expect} = sub {
my $pattern = shift // '';
my $tmout = shift // 1;
Expand Down
1 change: 1 addition & 0 deletions pac
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ if ( ! ( $PAC = PACMain -> new( @ARGV ) ) ) {
print STDERR "PAC not starting. PAC already running?\n";
exit 0
}
use Data::Dumper; print Dumper( PACUtils::_getXWindowsList );
$PAC -> start;

print "Finished $Script (PID:$$)...\n";
Expand Down
7 changes: 6 additions & 1 deletion res/pac.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Name[en_US]=PAC
Comment[en_US]=Perl Auto Connector
Categories=Applications;Network;
X-GNOME-Autostart-enabled=false
Actions=Shell;Quick;
Actions=Shell;Quick;ReadOnly;

[Desktop Action Shell]
Name=Start local shell
Expand All @@ -22,3 +22,8 @@ Name=Quick connect...
Exec=pac --quick-conn
#OnlyShowIn=Unity;

[Desktop Action ReadOnly]
Name=Start Read-Only instance
Exec=pac --readonly --no-backup
#OnlyShowIn=Unity;

0 comments on commit 024bcb2

Please sign in to comment.