mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-02-22 07:03:38 +00:00
Linux buildfix. Remove gamepad support from Linux.
Was required to rebuild. Would probably have to be rewritten any to support the new input system. Although keys can be remapped in the UI now, it would still be nice to have this done in the menu system.
This commit is contained in:
parent
a0aa6e3212
commit
f5246c07e3
@ -1,48 +0,0 @@
|
||||
#ifndef GAMEPADDIALOG_H
|
||||
#define GAMEPADDIALOG_H
|
||||
|
||||
#include <QDialog>
|
||||
#if QT_HAS_SDL
|
||||
#include "SDL/SDL.h"
|
||||
#endif
|
||||
#include "native/input/input_state.h"
|
||||
|
||||
namespace Ui {
|
||||
class GamePadDialog;
|
||||
}
|
||||
class QTimer;
|
||||
|
||||
class GamePadDialog : public QDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit GamePadDialog(InputState* inputState, QWidget *parent = 0);
|
||||
~GamePadDialog();
|
||||
|
||||
void SetViewMode();
|
||||
protected:
|
||||
void showEvent(QShowEvent *);
|
||||
void changeEvent(QEvent *);
|
||||
private slots:
|
||||
void releaseLock();
|
||||
void on_refreshListBtn_clicked();
|
||||
void on_SelectPadBtn_clicked();
|
||||
void pollJoystick();
|
||||
void on_AssignBtn_clicked();
|
||||
void on_buttonBox_accepted();
|
||||
private:
|
||||
int GetIntFromMapping(int inputId, int type, int sign);
|
||||
void GetMappingFromInt(int value, int &inputId, int &type, int &sign);
|
||||
|
||||
Ui::GamePadDialog *ui;
|
||||
#if QT_HAS_SDL
|
||||
SDL_Joystick* m_joystick;
|
||||
int m_joyId;
|
||||
#endif
|
||||
InputState* m_inputState;
|
||||
bool m_isInit;
|
||||
QTimer *data_timer;
|
||||
};
|
||||
|
||||
#endif // GAMEPADDIALOG_H
|
@ -1,512 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>GamePadDialog</class>
|
||||
<widget class="QDialog" name="GamePadDialog">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>850</width>
|
||||
<height>501</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Gamepad Configuration</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox">
|
||||
<property name="title">
|
||||
<string>GamePad List</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_3">
|
||||
<item>
|
||||
<widget class="QListWidget" name="GamePadList"/>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="refreshListBtn">
|
||||
<property name="text">
|
||||
<string>Refresh</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="SelectPadBtn">
|
||||
<property name="text">
|
||||
<string>Select</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="text">
|
||||
<string>Gamepad Values :</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QTreeWidget" name="padValues">
|
||||
<attribute name="headerVisible">
|
||||
<bool>false</bool>
|
||||
</attribute>
|
||||
<column>
|
||||
<property name="text">
|
||||
<string notr="true">1</string>
|
||||
</property>
|
||||
</column>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QLabel" name="JoyName">
|
||||
<property name="text">
|
||||
<string>TextLabel</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||
<item>
|
||||
<widget class="QLabel" name="label_2">
|
||||
<property name="text">
|
||||
<string>Assign Gamepad input</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="comboPadInput"/>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label_3">
|
||||
<property name="text">
|
||||
<string> to PSP button/axis</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="comboPSPButton"/>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="AssignBtn">
|
||||
<property name="text">
|
||||
<string>Assign</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label_4">
|
||||
<property name="text">
|
||||
<string>Press buttons on your gamePad to verify mapping :</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_4">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QWidget" name="widget" native="true">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>500</width>
|
||||
<height>218</height>
|
||||
</size>
|
||||
</property>
|
||||
<widget class="QLabel" name="PSPImg">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>500</width>
|
||||
<height>218</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_Up">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>110</x>
|
||||
<y>78</y>
|
||||
<width>21</width>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_up_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_Left">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>92</x>
|
||||
<y>93</y>
|
||||
<width>21</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_left_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_Right">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>122</x>
|
||||
<y>94</y>
|
||||
<width>20</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_right_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_Down">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>109</x>
|
||||
<y>105</y>
|
||||
<width>21</width>
|
||||
<height>30</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_down_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_Home">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>141</x>
|
||||
<y>165</y>
|
||||
<width>30</width>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_smallbtn_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_Select">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>312</x>
|
||||
<y>166</y>
|
||||
<width>21</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_smallbtn_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_Start">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>339</x>
|
||||
<y>166</y>
|
||||
<width>21</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_smallbtn_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_S">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>351</x>
|
||||
<y>92</y>
|
||||
<width>21</width>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_rightbtn_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_X">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>374</x>
|
||||
<y>114</y>
|
||||
<width>21</width>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_rightbtn_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_O">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>396</x>
|
||||
<y>93</y>
|
||||
<width>21</width>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_rightbtn_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_T">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>374</x>
|
||||
<y>71</y>
|
||||
<width>21</width>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_rightbtn_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_RT">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>351</x>
|
||||
<y>32</y>
|
||||
<width>61</width>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_rt_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_LT">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>93</x>
|
||||
<y>32</y>
|
||||
<width>60</width>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_lt_red.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_ADown">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>107</x>
|
||||
<y>144</y>
|
||||
<width>21</width>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_adown.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_ALeft">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>107</x>
|
||||
<y>139</y>
|
||||
<width>16</width>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_aleft.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_AUp">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>108</x>
|
||||
<y>134</y>
|
||||
<width>21</width>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_aup.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="Prev_ARight">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>118</x>
|
||||
<y>138</y>
|
||||
<width>21</width>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="resources.qrc">:/images/resources/psp_aright.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_3">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QDialogButtonBox" name="buttonBox">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="standardButtons">
|
||||
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<resources>
|
||||
<include location="resources.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>buttonBox</sender>
|
||||
<signal>accepted()</signal>
|
||||
<receiver>GamePadDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>248</x>
|
||||
<y>254</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>157</x>
|
||||
<y>274</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>buttonBox</sender>
|
||||
<signal>rejected()</signal>
|
||||
<receiver>GamePadDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>316</x>
|
||||
<y>260</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>286</x>
|
||||
<y>274</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
</ui>
|
@ -36,9 +36,6 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
ui->setupUi(this);
|
||||
|
||||
controls = new Controls(this);
|
||||
#if QT_HAS_SDL
|
||||
gamePadDlg = new GamePadDialog(&input_state, this);
|
||||
#endif
|
||||
|
||||
host = new QtHost(this);
|
||||
emugl = ui->widget;
|
||||
@ -462,15 +459,6 @@ void MainWindow::on_action_OptionsControls_triggered()
|
||||
controls->show();
|
||||
}
|
||||
|
||||
void MainWindow::on_action_OptionsGamePadControls_triggered()
|
||||
{
|
||||
#if QT_HAS_SDL
|
||||
gamePadDlg->show();
|
||||
#else
|
||||
QMessageBox::information(this,tr("Gamepad"),tr("You need to compile with SDL to have Gamepad support."), QMessageBox::Ok);
|
||||
#endif
|
||||
}
|
||||
|
||||
void MainWindow::on_action_AFOff_triggered()
|
||||
{
|
||||
g_Config.iAnisotropyLevel = 0;
|
||||
|
@ -11,7 +11,6 @@
|
||||
#include "debugger_memorytex.h"
|
||||
#include "debugger_displaylist.h"
|
||||
#include "controls.h"
|
||||
#include "gamepaddialog.h"
|
||||
|
||||
class QtEmuGL;
|
||||
namespace Ui {
|
||||
@ -82,7 +81,6 @@ private slots:
|
||||
|
||||
// Controls
|
||||
void on_action_OptionsControls_triggered();
|
||||
void on_action_OptionsGamePadControls_triggered();
|
||||
|
||||
// Video
|
||||
void on_action_AFOff_triggered();
|
||||
@ -160,7 +158,6 @@ private:
|
||||
Debugger_MemoryTex *memoryTexWindow;
|
||||
Debugger_DisplayList *displaylistWindow;
|
||||
Controls *controls;
|
||||
GamePadDialog *gamePadDlg;
|
||||
|
||||
QSet<int> pressedKeys;
|
||||
};
|
||||
|
@ -184,7 +184,6 @@
|
||||
<string>Co&ntrols</string>
|
||||
</property>
|
||||
<addaction name="action_OptionsControls"/>
|
||||
<addaction name="action_OptionsGamePadControls"/>
|
||||
</widget>
|
||||
<widget class="QMenu" name="menuCore">
|
||||
<property name="title">
|
||||
@ -592,11 +591,6 @@
|
||||
<string>Error</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="action_OptionsGamePadControls">
|
||||
<property name="text">
|
||||
<string>&Gamepad</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="action_EmulationRunLoad">
|
||||
<property name="text">
|
||||
<string>Run on loa&d</string>
|
||||
|
2
native
2
native
@ -1 +1 @@
|
||||
Subproject commit fad85942cd1ed23295e4eadd0d10f96bce0bca6d
|
||||
Subproject commit 9e2723b7816c7b8eac1b07a2dc4224b12ebc88a0
|
Loading…
x
Reference in New Issue
Block a user