Skip to content

Commit

Permalink
5:20 pm
Browse files Browse the repository at this point in the history
  • Loading branch information
richardyqn committed Jan 11, 2015
1 parent 34eabf9 commit f7f3f82
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 25 deletions.
42 changes: 25 additions & 17 deletions Richard_photoList/Richard_photoList.pro.user
Original file line number Diff line number Diff line change
@@ -1,14 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE QtCreatorProject>
<<<<<<< HEAD
<!-- Written by QtCreator 3.2.1, 2015-01-11T14:56:20. -->
=======
<!-- Written by QtCreator 3.2.1, 2014-12-23T14:52:55. -->
>>>>>>> FETCH_HEAD
<!-- Written by QtCreator 3.2.1, 2015-01-11T16:38:45. -->
<qtcreator>
<data>
<variable>EnvironmentId</variable>
<value type="QByteArray">{f0de3c19-7390-432f-8215-71267a77c807}</value>
<value type="QByteArray">{db3e1557-086a-4178-9b2c-c4af1acd9f93}</value>
</data>
<data>
<variable>ProjectExplorer.Project.ActiveTarget</variable>
Expand Down Expand Up @@ -62,14 +58,14 @@
<data>
<variable>ProjectExplorer.Project.Target.0</variable>
<valuemap type="QVariantMap">
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Desktop Qt 5.3 MSVC2010 OpenGL 32bit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Desktop Qt 5.3 MSVC2010 OpenGL 32bit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">qt.53.win32_msvc2010_opengl_kit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Desktop Qt 5.3 clang 64bit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Desktop Qt 5.3 clang 64bit</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">qt.53.clang_64_kit</value>
<value type="int" key="ProjectExplorer.Target.ActiveBuildConfiguration">0</value>
<value type="int" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
<value type="int" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.0">
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">C:/Jesse/groundstation/build-Richard_photoList-Desktop_Qt_5_3_MSVC2010_OpenGL_32bit-Debug</value>
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/Users/richardyu/Dropbox/build-Richard_photoList-Desktop_Qt_5_3_clang_64bit-Debug</value>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
Expand All @@ -86,7 +82,10 @@
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments"/>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
<value type="QString">-w</value>
<value type="QString">-r</value>
</valuelist>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
Expand All @@ -102,7 +101,10 @@
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments"/>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
<value type="QString">-w</value>
<value type="QString">-r</value>
</valuelist>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
Expand All @@ -122,7 +124,7 @@
<value type="bool" key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild">true</value>
</valuemap>
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.1">
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">C:/Jesse/groundstation/build-Richard_photoList-Desktop_Qt_5_3_MSVC2010_OpenGL_32bit-Release</value>
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/Users/richardyu/Dropbox/build-Richard_photoList-Desktop_Qt_5_3_clang_64bit-Release</value>
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
Expand All @@ -139,7 +141,10 @@
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments"/>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
<value type="QString">-w</value>
<value type="QString">-r</value>
</valuelist>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
Expand All @@ -155,7 +160,10 @@
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments"/>
<valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
<value type="QString">-w</value>
<value type="QString">-r</value>
</valuelist>
<value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
<value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
Expand Down Expand Up @@ -227,8 +235,8 @@
<value type="int" key="PE.EnvironmentAspect.Base">2</value>
<valuelist type="QVariantList" key="PE.EnvironmentAspect.Changes"/>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Richard_photoList</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4RunConfiguration:C:/Jesse/groundstation/Richard_photoList/Richard_photoList.pro</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Richard_photoList2</value>
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4RunConfiguration:/Users/richardyu/Documents/groundstation/Richard_photoList/Richard_photoList.pro</value>
<value type="QString" key="Qt4ProjectManager.Qt4RunConfiguration.CommandLineArguments"></value>
<value type="QString" key="Qt4ProjectManager.Qt4RunConfiguration.ProFile">Richard_photoList.pro</value>
<value type="bool" key="Qt4ProjectManager.Qt4RunConfiguration.UseDyldImageSuffix">false</value>
Expand Down
10 changes: 2 additions & 8 deletions Richard_photoList/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ MainWindow::MainWindow(QWidget *parent) :
// I want to display 100 rows of pictures
// each row contains 8 columns;
const int rows = 100;
const int columns = 4;
const int columns = 6;

dir = new QDir("/Users/richardyu/Pictures/photolist");
QStringList filters;
Expand All @@ -51,7 +51,6 @@ MainWindow::MainWindow(QWidget *parent) :
// for every row, display each column in the current row
for (int k = 0; k < rows; k=k+2) {
for (int j = 0; j < columns; j++) {
<<<<<<< HEAD

// When all files in the directory are added to the screen
// Jump out of the loop using 'goto'
Expand All @@ -61,9 +60,6 @@ MainWindow::MainWindow(QWidget *parent) :
QFileInfo fileinfo = list.at(listCount);

auto int index = k*columns + j;
=======
/*auto*/ int index = k*columns + j;
>>>>>>> FETCH_HEAD
imageLabel[index] = new QLabel();
imageName[index] = new QLabel();
imageMap[index] = new QPixmap(fileinfo.absoluteFilePath());
Expand Down Expand Up @@ -114,8 +110,6 @@ MainWindow::~MainWindow()
delete ui;
}



void MainWindow::on_hideImage_released()
{
clearImage();
Expand Down Expand Up @@ -157,7 +151,7 @@ void MainWindow::addImage() {
// for every row, display each column in the current row
for (int k = 0; k < rows; k++) {
for (int j = 0; j < columns; j++) {
/*auto*/ int index = k*columns + j;
auto int index = k*columns + j;
imageLabel[index] = new QLabel();
imageMap[index] = new QPixmap("/Users/richardyu/Pictures/conduct.png");
imageLabel[index]->setPixmap(imageMap[index] ->scaled(w,h,Qt::KeepAspectRatioByExpanding));
Expand Down

0 comments on commit f7f3f82

Please sign in to comment.