Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Konsole
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
2
Issues
2
List
Boards
Labels
Service Desk
Milestones
Merge Requests
23
Merge Requests
23
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Utilities
Konsole
Commits
6cfc3ed3
Commit
6cfc3ed3
authored
Mar 27, 2007
by
Robert Knight
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
KProcess -> K3Process, KProcIO -> K3ProcIO.
svn path=/branches/work/konsole-split-view/; revision=647320
parent
a44a76b8
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
50 additions
and
49 deletions
+50
-49
konsole/Pty.cpp
konsole/Pty.cpp
+5
-5
konsole/Pty.h
konsole/Pty.h
+6
-3
konsole/Session.cpp
konsole/Session.cpp
+13
-13
konsole/Session.h
konsole/Session.h
+7
-7
konsole/TerminalDisplay.cpp
konsole/TerminalDisplay.cpp
+6
-13
konsole/ViewContainer.cpp
konsole/ViewContainer.cpp
+0
-1
konsole/ViewManager.cpp
konsole/ViewManager.cpp
+12
-6
konsole/konsole.cpp
konsole/konsole.cpp
+1
-1
No files found.
konsole/Pty.cpp
View file @
6cfc3ed3
...
...
@@ -175,11 +175,11 @@ void Pty::setWriteable(bool writeable)
Pty
::
Pty
()
{
m_bufferFull
=
false
;
connect
(
this
,
SIGNAL
(
receivedStdout
(
KProcess
*
,
char
*
,
int
)),
this
,
SLOT
(
dataReceived
(
KProcess
*
,
char
*
,
int
)));
connect
(
this
,
SIGNAL
(
processExited
(
KProcess
*
)),
connect
(
this
,
SIGNAL
(
receivedStdout
(
K
3
Process
*
,
char
*
,
int
)),
this
,
SLOT
(
dataReceived
(
K
3
Process
*
,
char
*
,
int
)));
connect
(
this
,
SIGNAL
(
processExited
(
K
3
Process
*
)),
this
,
SLOT
(
donePty
()));
connect
(
this
,
SIGNAL
(
wroteStdin
(
KProcess
*
)),
connect
(
this
,
SIGNAL
(
wroteStdin
(
K
3
Process
*
)),
this
,
SLOT
(
writeReady
()));
setUsePty
(
All
,
false
);
// utmp will be overridden later
...
...
@@ -243,7 +243,7 @@ void Pty::send_bytes(const char* s, int len)
}
/*! indicates that a block of data is received */
void
Pty
::
dataReceived
(
KProcess
*
,
char
*
buf
,
int
len
)
void
Pty
::
dataReceived
(
K
3
Process
*
,
char
*
buf
,
int
len
)
{
// kDebug() << __FUNCTION__ << ": received " << len << " bytes - '" << buf << "'" << endl;
...
...
konsole/Pty.h
View file @
6cfc3ed3
...
...
@@ -21,16 +21,19 @@
#ifndef TE_PTY_H
#define TE_PTY_H
#include <kprocess.h>
// Qt
#include <QSocketNotifier>
#include <QStringList>
#include <QVector>
#include <QList>
// KDE
#include <K3Process>
namespace
Konsole
{
class
Pty
:
public
KProcess
class
Pty
:
public
K
3
Process
{
Q_OBJECT
...
...
@@ -85,7 +88,7 @@ Q_OBJECT
bool
buffer_full
()
{
return
m_bufferFull
;
}
protected
Q_SLOTS
:
void
dataReceived
(
KProcess
*
,
char
*
buf
,
int
len
);
void
dataReceived
(
K
3
Process
*
,
char
*
buf
,
int
len
);
public
Q_SLOTS
:
void
donePty
();
...
...
konsole/Session.cpp
View file @
6cfc3ed3
...
...
@@ -39,7 +39,7 @@
#include <KLocale>
#include <KMessageBox>
#include <KNotification>
#include <KProcIO>
#include <K
3
ProcIO>
#include <KRun>
#include <kshell.h>
#include <KStandardDirs>
...
...
@@ -770,7 +770,7 @@ void Session::cancelZModem()
void
Session
::
startZModem
(
const
QString
&
zmodem
,
const
QString
&
dir
,
const
QStringList
&
list
)
{
_zmodemBusy
=
true
;
_zmodemProc
=
new
KProcIO
;
_zmodemProc
=
new
K
3
ProcIO
;
(
*
_zmodemProc
)
<<
zmodem
<<
"-v"
;
for
(
QStringList
::
ConstIterator
it
=
list
.
begin
();
...
...
@@ -782,15 +782,15 @@ void Session::startZModem(const QString &zmodem, const QString &dir, const QStri
if
(
!
dir
.
isEmpty
())
_zmodemProc
->
setWorkingDirectory
(
dir
);
_zmodemProc
->
start
(
KProcIO
::
NotifyOnExit
,
false
);
// Override the read-processing of KProcIO
disconnect
(
_zmodemProc
,
SIGNAL
(
receivedStdout
(
KProcess
*
,
char
*
,
int
)),
0
,
0
);
connect
(
_zmodemProc
,
SIGNAL
(
receivedStdout
(
KProcess
*
,
char
*
,
int
)),
this
,
SLOT
(
zmodemSendBlock
(
KProcess
*
,
char
*
,
int
)));
connect
(
_zmodemProc
,
SIGNAL
(
receivedStderr
(
KProcess
*
,
char
*
,
int
)),
this
,
SLOT
(
zmodemStatus
(
KProcess
*
,
char
*
,
int
)));
connect
(
_zmodemProc
,
SIGNAL
(
processExited
(
KProcess
*
)),
_zmodemProc
->
start
(
K
3
ProcIO
::
NotifyOnExit
,
false
);
// Override the read-processing of K
3
ProcIO
disconnect
(
_zmodemProc
,
SIGNAL
(
receivedStdout
(
K
3
Process
*
,
char
*
,
int
)),
0
,
0
);
connect
(
_zmodemProc
,
SIGNAL
(
receivedStdout
(
K
3
Process
*
,
char
*
,
int
)),
this
,
SLOT
(
zmodemSendBlock
(
K
3
Process
*
,
char
*
,
int
)));
connect
(
_zmodemProc
,
SIGNAL
(
receivedStderr
(
K
3
Process
*
,
char
*
,
int
)),
this
,
SLOT
(
zmodemStatus
(
K
3
Process
*
,
char
*
,
int
)));
connect
(
_zmodemProc
,
SIGNAL
(
processExited
(
K
3
Process
*
)),
this
,
SLOT
(
zmodemDone
()));
disconnect
(
_shellProcess
,
SIGNAL
(
block_in
(
const
char
*
,
int
)),
this
,
SLOT
(
onReceiveBlock
(
const
char
*
,
int
))
);
...
...
@@ -806,7 +806,7 @@ void Session::startZModem(const QString &zmodem, const QString &dir, const QStri
_zmodemProgress
->
show
();
}
void
Session
::
zmodemSendBlock
(
KProcess
*
,
char
*
data
,
int
len
)
void
Session
::
zmodemSendBlock
(
K
3
Process
*
,
char
*
data
,
int
len
)
{
_shellProcess
->
send_bytes
(
data
,
len
);
// qWarning("<-- %d bytes", len);
...
...
@@ -823,7 +823,7 @@ void Session::zmodemContinue()
// qWarning("ZModem resume");
}
void
Session
::
zmodemStatus
(
KProcess
*
,
char
*
data
,
int
len
)
void
Session
::
zmodemStatus
(
K
3
Process
*
,
char
*
data
,
int
len
)
{
QByteArray
msg
(
data
,
len
+
1
);
while
(
!
msg
.
isEmpty
())
...
...
konsole/Session.h
View file @
6cfc3ed3
...
...
@@ -26,8 +26,8 @@
#include <QByteArray>
// KDE
#include <
kapplication.h
>
#include <
kmainwindow.h
>
#include <
KApplication
>
#include <
KMainWindow
>
// Konsole
#include "Pty.h"
...
...
@@ -35,8 +35,8 @@
#include "Vt102Emulation.h"
class
KProcIO
;
class
KProcess
;
class
K
3
ProcIO
;
class
K
3
Process
;
namespace
Konsole
{
...
...
@@ -236,8 +236,8 @@ public Q_SLOTS:
void
slotZModemDetected
();
void
emitZModemDetected
();
void
zmodemStatus
(
KProcess
*
,
char
*
data
,
int
len
);
void
zmodemSendBlock
(
KProcess
*
,
char
*
data
,
int
len
);
void
zmodemStatus
(
K
3
Process
*
,
char
*
data
,
int
len
);
void
zmodemSendBlock
(
K
3
Process
*
,
char
*
data
,
int
len
);
void
zmodemRcvBlock
(
const
char
*
data
,
int
len
);
void
zmodemDone
();
void
zmodemContinue
();
...
...
@@ -321,7 +321,7 @@ private:
// ZModem
bool
_zmodemBusy
;
KProcIO
*
_zmodemProc
;
K
3
ProcIO
*
_zmodemProc
;
ZModemDialog
*
_zmodemProgress
;
// Color/Font Changes by ESC Sequences
...
...
konsole/TerminalDisplay.cpp
View file @
6cfc3ed3
...
...
@@ -2431,6 +2431,12 @@ bool TerminalDisplay::eventFilter( QObject *obj, QEvent *e )
if
(
ke
->
modifiers
()
&
Qt
::
ControlModifier
)
{
/*if ( ke->key() == Qt::Key_PageUp || ke->key() == Qt::Key_PageDown)
{
static_cast<QKeyEvent*>(e)->ignore();
return false;
}*/
if
(
ke
->
key
()
==
Qt
::
Key_S
)
emit
flowControlKeyPressed
(
true
/*output suspended*/
);
if
(
ke
->
key
()
==
Qt
::
Key_Q
)
...
...
@@ -2460,19 +2466,6 @@ bool TerminalDisplay::eventFilter( QObject *obj, QEvent *e )
return
true
;
}
// We no longer clear the selection when the clipboard changes
//
//if ( e->type() == QEvent::Enter )
//{
// QObject::disconnect( (QObject*)cb, SIGNAL(dataChanged()),
// this, SLOT(onClearSelection()) );
//}
//if ( e->type() == QEvent::Leave )
//{
// QObject::connect( (QObject*)cb, SIGNAL(dataChanged()),
// this, SLOT(onClearSelection()) );
//}*/
return
QFrame
::
eventFilter
(
obj
,
e
);
}
...
...
konsole/ViewContainer.cpp
View file @
6cfc3ed3
...
...
@@ -144,7 +144,6 @@ TabbedViewContainer::TabbedViewContainer(QObject* parent) :
,
_contextMenuTab
(
0
)
{
_tabWidget
=
new
KTabWidget
();
_tabWidget
->
setDrawTabFrame
(
false
);
_tabContextMenu
=
new
KMenu
(
_tabWidget
);
_newSessionButton
=
new
QToolButton
(
_tabWidget
);
...
...
konsole/ViewManager.cpp
View file @
6cfc3ed3
...
...
@@ -92,15 +92,21 @@ void ViewManager::setupActions()
connect
(
mergeAction
,
SIGNAL
(
triggered
())
,
_mainWindow
,
SLOT
(
mergeWindows
())
);
QAction
*
nextViewAction
=
collection
->
addAction
(
"next-view"
);
nextViewAction
->
setText
(
i18n
(
"Next View"
)
);
nextViewAction
->
setShortcut
(
QKeySequence
(
Qt
::
SHIFT
+
Qt
::
Key_Right
)
);
KAction
*
nextViewAction
=
new
KAction
(
i18n
(
"Next View"
)
,
this
);
collection
->
addAction
(
"next-view"
,
nextViewAction
);
KShortcut
nextViewShortcut
=
nextViewAction
->
shortcut
();
nextViewShortcut
.
setAlternate
(
QKeySequence
(
Qt
::
SHIFT
+
Qt
::
Key_Right
)
);
nextViewShortcut
.
setPrimary
(
QKeySequence
(
Qt
::
CTRL
+
Qt
::
Key_PageUp
)
);
nextViewAction
->
setShortcut
(
nextViewShortcut
);
connect
(
nextViewAction
,
SIGNAL
(
triggered
())
,
this
,
SLOT
(
nextView
())
);
_mainWindow
->
addAction
(
nextViewAction
);
QAction
*
previousViewAction
=
collection
->
addAction
(
"previous-view"
);
previousViewAction
->
setText
(
i18n
(
"Previous View"
)
);
previousViewAction
->
setShortcut
(
QKeySequence
(
Qt
::
SHIFT
+
Qt
::
Key_Left
)
);
KAction
*
previousViewAction
=
new
KAction
(
i18n
(
"Previous View"
)
,
this
);
collection
->
addAction
(
"previous-view"
,
previousViewAction
);
KShortcut
previousViewShortcut
=
previousViewAction
->
shortcut
();
previousViewShortcut
.
setPrimary
(
QKeySequence
(
Qt
::
SHIFT
+
Qt
::
Key_Left
)
);
previousViewShortcut
.
setAlternate
(
QKeySequence
(
Qt
::
CTRL
+
Qt
::
Key_PageDown
)
);
previousViewAction
->
setShortcut
(
previousViewShortcut
);
connect
(
previousViewAction
,
SIGNAL
(
triggered
())
,
this
,
SLOT
(
previousView
())
);
_mainWindow
->
addAction
(
previousViewAction
);
...
...
konsole/konsole.cpp
View file @
6cfc3ed3
...
...
@@ -350,7 +350,7 @@ Konsole::~Konsole()
//wait for the session processes to terminate
while
(
sessionManager
()
->
sessions
().
count
()
&&
K
ProcessController
::
theK
ProcessController
->
waitForProcessExit
(
1
))
K
3ProcessController
::
theK3
ProcessController
->
waitForProcessExit
(
1
))
{
//do nothing
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment