Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PR: Make QAction.setShortcut and setShortcuts accept many types #461

Merged
merged 16 commits into from
Nov 9, 2023

Commits on Oct 18, 2023

  1. Test QMenu.addAction with various shortcut types

    Test `QMenu.addAction` with a shortcut of `Qt.Key` type as well. The argument type causes the following error on `PySide2`:
    ```plaintext
    TypeError: 'PySide2.QtWidgets.QAction.setShortcut' called with wrong argument types:
      PySide2.QtWidgets.QAction.setShortcut(Key)
    Supported signatures:
      PySide2.QtWidgets.QAction.setShortcut(PySide2.QtGui.QKeySequence)
    ```
    StSav012 authored Oct 18, 2023
    Configuration menu
    Copy the full SHA
    df81709 View commit details
    Browse the repository at this point in the history

Commits on Oct 19, 2023

  1. Configuration menu
    Copy the full SHA
    019517c View commit details
    Browse the repository at this point in the history
  2. Make QAction.setShortcut(s) accept many types

    Fix the omission of `Qt.Key` check.
    Fix a crash when `QAction.setShortcuts` gets a single shortcut.
    Add tests for the cases.
    Refactor a little.
    StSav012 committed Oct 19, 2023
    Configuration menu
    Copy the full SHA
    49f0b75 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    d6f2739 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    bc7cc97 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    b4d3e1d View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    80bb648 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    7c5100d View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    849a349 View commit details
    Browse the repository at this point in the history
  9. Patch addAction for Qt < 6.4

    Some 6.3.2 builds still seem to lack the flexibility.
    StSav012 committed Oct 19, 2023
    Configuration menu
    Copy the full SHA
    d8afeb0 View commit details
    Browse the repository at this point in the history

Commits on Oct 24, 2023

  1. Configuration menu
    Copy the full SHA
    a2451e1 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    674183d View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    855e832 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    429fd3d View commit details
    Browse the repository at this point in the history
  5. Test whether QAction.setShortcuts doesn't support a Qt.Key argume…

    …nt as suggested by @ccordoba12
    
    The test is expected to fail on Qt6 >= 6.5.
    The earlier versions of PyQt/PySide are patched against the fail, so don't test them.
    StSav012 committed Oct 24, 2023
    Configuration menu
    Copy the full SHA
    2c299ff View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    c8d1144 View commit details
    Browse the repository at this point in the history