Cockatrice
2026-10-19-Development-3.1.2-beta.2
A virtual tabletop for multiplayer card games
Toggle main menu visibility
Loading...
Searching...
No Matches
share_bar_widget.h
Go to the documentation of this file.
1
6
7
#ifndef SHARE_BAR_WIDGET_H
8
#define SHARE_BAR_WIDGET_H
9
10
#include <QString>
11
#include <QWidget>
12
#include <qtmetamacros.h>
13
14
class
QLabel;
15
class
QLineEdit;
16
class
QPushButton;
17
26
class
ShareBarWidget
final :
public
QWidget
27
{
28
Q_OBJECT
29
30
public
:
31
explicit
ShareBarWidget
(QWidget *parent =
nullptr
);
32
33
void
retranslateUi
();
34
36
[[nodiscard]] QString
name
()
const
;
37
39
void
setName
(
const
QString &
name
);
40
42
void
setCountText
(
const
QString &text);
43
45
void
setHintText
(
const
QString &text,
bool
visible);
46
48
void
setCreateEnabled
(
bool
enabled);
49
51
void
focusName
();
52
53
signals:
54
void
createRequested
();
55
void
cancelRequested
();
56
57
private
:
58
QLabel *
hintLabel
;
59
QLineEdit *
nameEdit
;
60
QLabel *
countLabel
;
61
QPushButton *
cancelButton
;
62
QPushButton *
createButton
;
63
};
64
65
#endif
// SHARE_BAR_WIDGET_H
ShareBarWidget::nameEdit
QLineEdit * nameEdit
Definition
share_bar_widget.h:59
ShareBarWidget::setCountText
void setCountText(const QString &text)
Sets the selected-count summary label text.
Definition
share_bar_widget.cpp:58
ShareBarWidget::setCreateEnabled
void setCreateEnabled(bool enabled)
Enables or disables the create-share-link button (guards double submission).
Definition
share_bar_widget.cpp:69
ShareBarWidget::focusName
void focusName()
Moves keyboard focus to the name field.
Definition
share_bar_widget.cpp:74
ShareBarWidget::hintLabel
QLabel * hintLabel
Definition
share_bar_widget.h:58
ShareBarWidget::name
QString name() const
Definition
share_bar_widget.cpp:48
ShareBarWidget::countLabel
QLabel * countLabel
Definition
share_bar_widget.h:60
ShareBarWidget::cancelRequested
void cancelRequested()
ShareBarWidget::createRequested
void createRequested()
ShareBarWidget::createButton
QPushButton * createButton
Definition
share_bar_widget.h:62
ShareBarWidget::retranslateUi
void retranslateUi()
Definition
share_bar_widget.cpp:41
ShareBarWidget::setName
void setName(const QString &name)
Resets the name field to the given default.
Definition
share_bar_widget.cpp:53
ShareBarWidget::cancelButton
QPushButton * cancelButton
Definition
share_bar_widget.h:61
ShareBarWidget::ShareBarWidget
ShareBarWidget(QWidget *parent=nullptr)
Definition
share_bar_widget.cpp:8
ShareBarWidget::setHintText
void setHintText(const QString &text, bool visible)
Sets the explainer hint text, showing it when visible is true.
Definition
share_bar_widget.cpp:63
cockatrice
src
interface
widgets
deck_share
share_bar_widget.h
Generated by
1.18.0