Skip to content

Commit 5fbeba8

Browse files
author
Volker Kohaupt
committed
Concatenating strings
1 parent c142f66 commit 5fbeba8

File tree

4 files changed

+21
-59
lines changed

4 files changed

+21
-59
lines changed

lineCounter.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/bin/bash
2+
3+
find . -name '*.cpp' -type f -print0 | xargs -0 cat | wc -l
4+
find . -name '*.h' -type f -print0 | xargs -0 cat | wc -l

main.ts

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -152,14 +152,6 @@
152152
<source>Open Directory</source>
153153
<translation type="unfinished"></translation>
154154
</message>
155-
<message>
156-
<source>Device </source>
157-
<translation type="unfinished"></translation>
158-
</message>
159-
<message>
160-
<source> is busy</source>
161-
<translation type="unfinished"></translation>
162-
</message>
163155
<message>
164156
<source>%1</source>
165157
<translation type="unfinished"></translation>
@@ -184,5 +176,9 @@
184176
<source>Actual frames per second</source>
185177
<translation type="unfinished"></translation>
186178
</message>
179+
<message>
180+
<source>Device %1 is busy</source>
181+
<translation type="unfinished"></translation>
182+
</message>
187183
</context>
188184
</TS>

screencast.cpp

Lines changed: 13 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -18,22 +18,11 @@
1818

1919
#include <QX11Info>
2020
#include <QScreen>
21-
using namespace std;
2221

23-
/// ffmpeg -i <rein> -vcodec libx264 -b 2048k -s 720x576 -acodec libmp3lame -ab 128k -ar 48000 -ac 2 -f matroska -y <raus>.mkv
22+
using namespace std;
2423

2524
screencast::screencast()
2625
{
27-
/*
28-
TestFrame = new QMainWindow();
29-
TestFrame->setGeometry( 0, 0, 100, 100 );
30-
TestFrame->show();
31-
//TestFrame->setPaletteForegroundColor(Qt::white);
32-
qDebug() << "X():" << TestFrame->x() << "Y():" << TestFrame->y();
33-
qDebug() << "geometry.x()" << TestFrame->geometry().x() << "geometry.y()" << TestFrame->geometry().y();
34-
qDebug() << "frameGeometry.width()" << TestFrame->frameGeometry().width() << "frameGeometry.height()" << TestFrame->frameGeometry().height();
35-
*/
36-
3726
bool beta = true;
3827
QString Beta;
3928
if ( beta )
@@ -136,7 +125,6 @@ screencast::screencast()
136125
}
137126
qDebug() << "[vokoscreen]" << "---End search Screen---";
138127
qDebug();
139-
// am 16.07.2013 22:20 auf github
140128

141129
QLabel *CountdownLabel = new QLabel( frame );
142130
CountdownLabel->setGeometry( 160, 110, 80, 25 );
@@ -185,7 +173,6 @@ screencast::screencast()
185173
PulseDeviceRadioButton->show();
186174
connect( PulseDeviceRadioButton, SIGNAL( clicked( bool ) ), SLOT( clickedAudioPulse( bool ) ) );
187175

188-
189176
// Tab 3 Video options **************************************************
190177
TabWidgetVideoOptionFrame = new QFrame( this );
191178
TabWidgetVideoOptionFrame->setGeometry( 120, 0, 300, 200 );
@@ -260,7 +247,6 @@ screencast::screencast()
260247
qfont = TabWidgetMiscellaneousFrame->font();
261248
qfont.setPixelSize( 12 );
262249
TabWidgetMiscellaneousFrame->setFont( qfont );
263-
264250

265251
QLabel *SaveVideoPathLabel = new QLabel(TabWidgetMiscellaneousFrame);
266252
SaveVideoPathLabel->setGeometry(30,30,210,25);
@@ -333,7 +319,6 @@ screencast::screencast()
333319
QLabel* labelMail = new QLabel( TabWidgetAboutFrame );
334320
labelMail->setGeometry( QRect( 180, 50, 400, 22 ) );
335321
labelMail->setText( email );
336-
//labelMail->setAlignment( Qt::AlignCenter );
337322
labelMail->setOpenExternalLinks( true );
338323
labelMail->show();
339324

@@ -544,8 +529,6 @@ screencast::screencast()
544529
}
545530
}
546531
}
547-
//todo
548-
//Standard Videoplayer hinzufügen und in vokoscreen als Standard setzen
549532

550533
qDebug() << "[vokoscreen]" << "---End search Videoplayer---";
551534
qDebug();
@@ -753,20 +736,6 @@ void screencast::valueChangedFrames( int i )
753736
}
754737

755738

756-
/**
757-
* Statusbar
758-
*/
759-
/*
760-
void screencast::stateChangedAutoFrames( int state )
761-
{
762-
(void)state;
763-
if ( FramesAutoOnOffCheckBox->checkState() == Qt::Checked )
764-
statusBarLabelFpsSettings->setText( "Auto" );
765-
else
766-
statusBarLabelFpsSettings->setText( QString::number( FrameSpinBox->value() ) );
767-
}
768-
*/
769-
770739
/**
771740
* Statusbar
772741
*/
@@ -853,7 +822,6 @@ void screencast::myVideoFileSystemWatcher( const QString & path )
853822
}
854823

855824

856-
857825
/*
858826
QString boolToStr( bool boo )
859827
{
@@ -1322,7 +1290,7 @@ void screencast::error( QProcess::ProcessError error )
13221290
// Kann mann testen in dem man den ffmpeg aus der Processliste tötet
13231291
if ( error == QProcess::Crashed )
13241292
{
1325-
// crashed Ordner löschen
1293+
// remove crashed directory
13261294
QSettings settings1( ProgName, ProgName );
13271295
QFileInfo settingsPath1( settings1.fileName() );
13281296
QFile file1( settingsPath1.absolutePath() );
@@ -1336,7 +1304,7 @@ void screencast::error( QProcess::ProcessError error )
13361304
Dir1.remove( stringList1[ i ] );
13371305
}
13381306

1339-
// Sichern von ffmpeg.log, vokoscreen.log, vokoscreen.conf im Ordner crashed
1307+
// Move ffmpeg.log, vokoscreen.log, vokoscreen.conf in directory crashed
13401308
QSettings settings( ProgName, ProgName );
13411309
QFileInfo settingsPath( settings.fileName() );
13421310
QFile file( settingsPath.absolutePath() );
@@ -1437,12 +1405,13 @@ void screencast::Pause()
14371405
{
14381406
QMessageBox msgBox;
14391407
QString message;
1440-
message.append( tr( "Device " ) );
1408+
/*message.append( tr( "Device " ) );
14411409
message.append( " " );
14421410
message.append( inBox->getAlsaHw() );
14431411
message.append( " " );
1444-
message.append( tr( " is busy" ) );
1445-
msgBox.setText( message );
1412+
message.append( tr( " is busy" ) ); */
1413+
message.append( tr( "Device %1 is busy" ).arg( inBox->getAlsaHw() ) );
1414+
msgBox.setText( message );
14461415
msgBox.exec();
14471416
PauseButton->click();
14481417
return;
@@ -1475,11 +1444,12 @@ void screencast::Pause()
14751444
{
14761445
QMessageBox msgBox;
14771446
QString message;
1478-
message.append( tr( "Device " ) );
1447+
/*message.append( tr( "Device " ) );
14791448
message.append( " " );
14801449
message.append( inBox->getAlsaHw() );
14811450
message.append( " " );
1482-
message.append( tr( " is busy" ) );
1451+
message.append( tr( " is busy" ) ); */
1452+
message.append( tr( "Device %1 is busy" ).arg( inBox->getAlsaHw() ) );
14831453
msgBox.setText( message );
14841454
msgBox.exec();
14851455
PauseButton->click();
@@ -1780,7 +1750,6 @@ QString screencast::mySample()
17801750
}
17811751

17821752
return ret;
1783-
17841753
}
17851754

17861755

@@ -2155,11 +2124,12 @@ void screencast::preRecord()
21552124
QMessageBox msgBox;
21562125
msgBox.setIcon( QMessageBox::Information );
21572126
QString message;
2158-
message.append( tr( "Device " ) );
2127+
/*message.append( tr( "Device " ) );
21592128
message.append( " " );
21602129
message.append( inBox->getAlsaHw() );
21612130
message.append( " " );
2162-
message.append( tr( " is busy" ) );
2131+
message.append( tr( " is busy" ) ); */
2132+
message.append( tr( "Device %1 is busy" ).arg( inBox->getAlsaHw() ) );
21632133
msgBox.setText( message );
21642134
msgBox.exec();
21652135
return;
@@ -2357,7 +2327,6 @@ void screencast::record()
23572327
myReport = "";
23582328

23592329
qDebug() << "[vokoscreen]" << "Report :" << myReport;
2360-
//qDebug() << "[vokoscreen]" << "ffmpegVersion :" << getFfmpegVersion();
23612330

23622331
// set working directory for writing and delete the ffmpegLog from Profil directory
23632332
QSettings settings( ProgName, ProgName );
@@ -2384,14 +2353,8 @@ void screencast::record()
23842353
dir.remove( PathTempLocation().append(QDir::separator() ).append(stringList.at( i ) ) );
23852354

23862355
// frame rate
2387-
//QString frame = QString().number( FrameSpinBox->value() );
23882356
QString frame = "-r " + QString().number( FrameSpinBox->value() );
23892357

2390-
//if ( FramesAutoOnOffCheckBox->checkState() == Qt::Checked )
2391-
//frame = "";
2392-
//else
2393-
//frame = "-r " + frame;
2394-
23952358
// Videocodec
23962359
QString myVcodec = VideocodecComboBox->currentText();
23972360
if ( myVcodec == "libx264" )

screencast.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,6 @@ private slots:
153153
void stateChangedAudio( int state );
154154
void clickedAudioAlsa( bool checked );
155155
void clickedAudioPulse( bool checked );
156-
//void stateChangedAutoFrames( int state);;
157156
void valueChangedFrames( int i );
158157
void clickedScreenSize();
159158
void clickedRecordButtonScreenSize();

0 commit comments

Comments
 (0)