forked from qt-creator/qt-creator
		
	Fixes: Move icons into VCSBase, use buttons for submit
This commit is contained in:
		@@ -625,7 +625,7 @@ QString GitClient::readConfig(const QString &workingDirectory, const QStringList
 | 
			
		||||
 | 
			
		||||
    QByteArray outputText;
 | 
			
		||||
    if (synchronousGit(workingDirectory, arguments, &outputText))
 | 
			
		||||
        return outputText;
 | 
			
		||||
        return QString::fromLocal8Bit(outputText);
 | 
			
		||||
    return QString();
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -48,10 +48,6 @@ const char * const SUBMIT_CURRENT = "Nokia.Git.SubmitCurrentLog";
 | 
			
		||||
const char * const DIFF_SELECTED = "Nokia.Git.DiffSelectedFilesInLog";
 | 
			
		||||
const char * const SUBMIT_MIMETYPE = "application/vnd.nokia.text.git.submit";
 | 
			
		||||
 | 
			
		||||
// TODO: For the moment, trust p4 is loaded...
 | 
			
		||||
const char * const ICON_SUBMIT = ":/trolltech.perforce/images/submit.png";
 | 
			
		||||
const char * const ICON_DIFF = ":/trolltech.perforce/images/diff.png";
 | 
			
		||||
 | 
			
		||||
const char * const DIFF_FILE_INDICATOR = "--- ";
 | 
			
		||||
enum { debug = 0 };
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -354,12 +354,12 @@ bool GitPlugin::initialize(const QStringList &arguments, QString *error_message)
 | 
			
		||||
    // Submit editor
 | 
			
		||||
    QList<int> submitContext;
 | 
			
		||||
    submitContext.push_back(m_core->uniqueIDManager()->uniqueIdentifier(QLatin1String(Constants::C_GITSUBMITEDITOR)));
 | 
			
		||||
    m_submitCurrentAction = new QAction(QIcon(Constants::ICON_SUBMIT), tr("Commit"), this);
 | 
			
		||||
    m_submitCurrentAction = new QAction(VCSBase::VCSBaseSubmitEditor::submitIcon(), tr("Commit"), this);
 | 
			
		||||
    command = actionManager->registerAction(m_submitCurrentAction, Constants::SUBMIT_CURRENT, submitContext);
 | 
			
		||||
    // TODO
 | 
			
		||||
    connect(m_submitCurrentAction, SIGNAL(triggered()), this, SLOT(submitCurrentLog()));
 | 
			
		||||
 | 
			
		||||
    m_diffSelectedFilesAction = new QAction(QIcon(Constants::ICON_DIFF), tr("Diff Selected Files"), this);
 | 
			
		||||
    m_diffSelectedFilesAction = new QAction(VCSBase::VCSBaseSubmitEditor::diffIcon(), tr("Diff Selected Files"), this);
 | 
			
		||||
    command = actionManager->registerAction(m_diffSelectedFilesAction, Constants::DIFF_SELECTED, submitContext);
 | 
			
		||||
 | 
			
		||||
    m_undoAction = new QAction(tr("&Undo"), this);
 | 
			
		||||
 
 | 
			
		||||
@@ -48,7 +48,6 @@ GitSubmitEditorWidget::GitSubmitEditorWidget(QWidget *parent) :
 | 
			
		||||
void GitSubmitEditorWidget::setPanelInfo(const GitSubmitEditorPanelInfo &info)
 | 
			
		||||
{
 | 
			
		||||
    m_gitSubmitPanelUi.repositoryLabel->setText(info.repository);
 | 
			
		||||
    m_gitSubmitPanelUi.descriptionLabel->setText(info.description);
 | 
			
		||||
    m_gitSubmitPanelUi.branchLabel->setText(info.branch);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -7,7 +7,7 @@
 | 
			
		||||
    <x>0</x>
 | 
			
		||||
    <y>0</y>
 | 
			
		||||
    <width>201</width>
 | 
			
		||||
    <height>210</height>
 | 
			
		||||
    <height>189</height>
 | 
			
		||||
   </rect>
 | 
			
		||||
  </property>
 | 
			
		||||
  <layout class="QVBoxLayout" name="verticalLayout">
 | 
			
		||||
@@ -17,6 +17,9 @@
 | 
			
		||||
      <string>General Information</string>
 | 
			
		||||
     </property>
 | 
			
		||||
     <layout class="QFormLayout" name="infoFormLayout">
 | 
			
		||||
      <property name="fieldGrowthPolicy">
 | 
			
		||||
       <enum>QFormLayout::ExpandingFieldsGrow</enum>
 | 
			
		||||
      </property>
 | 
			
		||||
      <item row="0" column="0">
 | 
			
		||||
       <widget class="QLabel" name="repositoryLabelLabel">
 | 
			
		||||
        <property name="text">
 | 
			
		||||
@@ -32,30 +35,13 @@
 | 
			
		||||
       </widget>
 | 
			
		||||
      </item>
 | 
			
		||||
      <item row="1" column="0">
 | 
			
		||||
       <widget class="QLabel" name="descriptionLabelLabel">
 | 
			
		||||
        <property name="text">
 | 
			
		||||
         <string>Description:</string>
 | 
			
		||||
        </property>
 | 
			
		||||
       </widget>
 | 
			
		||||
      </item>
 | 
			
		||||
      <item row="1" column="1">
 | 
			
		||||
       <widget class="QLabel" name="descriptionLabel">
 | 
			
		||||
        <property name="enabled">
 | 
			
		||||
         <bool>true</bool>
 | 
			
		||||
        </property>
 | 
			
		||||
        <property name="text">
 | 
			
		||||
         <string>description</string>
 | 
			
		||||
        </property>
 | 
			
		||||
       </widget>
 | 
			
		||||
      </item>
 | 
			
		||||
      <item row="2" column="0">
 | 
			
		||||
       <widget class="QLabel" name="branchLabelLabel">
 | 
			
		||||
        <property name="text">
 | 
			
		||||
         <string>Branch:</string>
 | 
			
		||||
        </property>
 | 
			
		||||
       </widget>
 | 
			
		||||
      </item>
 | 
			
		||||
      <item row="2" column="1">
 | 
			
		||||
      <item row="1" column="1">
 | 
			
		||||
       <widget class="QLabel" name="branchLabel">
 | 
			
		||||
        <property name="text">
 | 
			
		||||
         <string>branch</string>
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user