MCPcopy Create free account
hub / github.com/RGAA-Software/GoDesk / ComputerIcon

Method ComputerIcon

src/client/ui/computer_icon.cpp:11–17  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9{
10
11 ComputerIcon::ComputerIcon(const std::shared_ptr<ClientContext>& ctx, int idx, QWidget* parent) : BaseWidget(ctx, parent) {
12 QImage image;
13 image.load(":resources/image/ic_computer.svg");
14 pixmap_ = QPixmap::fromImage(image);
15 pixmap_ = pixmap_.scaled(icon_size_, icon_size_, Qt::KeepAspectRatio, Qt::SmoothTransformation);
16 monitor_index_ = idx;
17 }
18
19 void ComputerIcon::paintEvent(QPaintEvent *event) {
20 QPainter painter(this);

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected