Fix evidence not being consistently presentable (#1048)
* Fixup evidence presentation code, methink * Bump RC, because I can
This commit is contained in:
		
							parent
							
								
									0c10f03150
								
							
						
					
					
						commit
						fedf26075a
					
				@ -119,7 +119,7 @@ void AOApplication::destruct_courtroom()
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
QString AOApplication::get_version_string()
 | 
					QString AOApplication::get_version_string()
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
  return QString::number(RELEASE) + "." + QString::number(MAJOR_VERSION) + "." + QString::number(MINOR_VERSION) + " RC4";
 | 
					  return QString::number(RELEASE) + "." + QString::number(MAJOR_VERSION) + "." + QString::number(MINOR_VERSION) + " RC5";
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
QString AOApplication::find_image(QStringList p_list)
 | 
					QString AOApplication::find_image(QStringList p_list)
 | 
				
			||||||
 | 
				
			|||||||
@ -1,7 +1,6 @@
 | 
				
			|||||||
#include "aoevidencedisplay.h"
 | 
					#include "aoevidencedisplay.h"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "datatypes.h"
 | 
					#include "datatypes.h"
 | 
				
			||||||
#include "file_functions.h"
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
AOEvidenceDisplay::AOEvidenceDisplay(AOApplication *p_ao_app, QWidget *p_parent)
 | 
					AOEvidenceDisplay::AOEvidenceDisplay(AOApplication *p_ao_app, QWidget *p_parent)
 | 
				
			||||||
    : QLabel(p_parent)
 | 
					    : QLabel(p_parent)
 | 
				
			||||||
@ -91,3 +90,8 @@ void AOEvidenceDisplay::combo_resize(int w, int h)
 | 
				
			|||||||
  this->resize(f_size);
 | 
					  this->resize(f_size);
 | 
				
			||||||
  m_evidence_movie->resize(w, h);
 | 
					  m_evidence_movie->resize(w, h);
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					void AOEvidenceDisplay::setLastEvidenceIndex(int f_index)
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
					  m_last_evidence_index = f_index;
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
@ -18,6 +18,7 @@ public:
 | 
				
			|||||||
  void show_evidence(int p_index, QString p_evidence_image, bool is_left_side, int p_volume);
 | 
					  void show_evidence(int p_index, QString p_evidence_image, bool is_left_side, int p_volume);
 | 
				
			||||||
  void reset();
 | 
					  void reset();
 | 
				
			||||||
  void combo_resize(int w, int h);
 | 
					  void combo_resize(int w, int h);
 | 
				
			||||||
 | 
					  void setLastEvidenceIndex(int f_index);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Q_SIGNALS:
 | 
					Q_SIGNALS:
 | 
				
			||||||
  void show_evidence_details(int index);
 | 
					  void show_evidence_details(int index);
 | 
				
			||||||
 | 
				
			|||||||
@ -3393,9 +3393,13 @@ void Courtroom::display_evidence_image()
 | 
				
			|||||||
    QString f_image = local_evidence_list.at(f_evi_id - 1).image;
 | 
					    QString f_image = local_evidence_list.at(f_evi_id - 1).image;
 | 
				
			||||||
    // QString f_evi_name = local_evidence_list.at(f_evi_id - 1).name;
 | 
					    // QString f_evi_name = local_evidence_list.at(f_evi_id - 1).name;
 | 
				
			||||||
    //  def jud and hlp should display the evidence icon on the RIGHT side
 | 
					    //  def jud and hlp should display the evidence icon on the RIGHT side
 | 
				
			||||||
    bool is_left_side = !(side.startsWith("def") || side == "hlp");
 | 
					    bool is_left_side = !(side.startsWith("def") || side == "hlp"); // FIXME : Hardcoded
 | 
				
			||||||
    ui_vp_evidence_display->show_evidence(f_evi_id, f_image, is_left_side, sfx_player->volume());
 | 
					    ui_vp_evidence_display->show_evidence(f_evi_id, f_image, is_left_side, sfx_player->volume());
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					  else
 | 
				
			||||||
 | 
					  {
 | 
				
			||||||
 | 
					    ui_vp_evidence_display->setLastEvidenceIndex(-1);
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void Courtroom::handle_ic_speaking()
 | 
					void Courtroom::handle_ic_speaking()
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user