MCPcopy Create free account
hub / github.com/OpenApoc/OpenApoc / copyControlData

Method copyControlData

forms/control.cpp:1031–1056  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1029}
1030
1031void Control::copyControlData(sp<Control> CopyOf)
1032{
1033 lastCopiedTo = CopyOf;
1034
1035 CopyOf->Name = this->Name;
1036 CopyOf->Location = this->Location;
1037 CopyOf->Size = this->Size;
1038 CopyOf->SelectionSize = this->SelectionSize;
1039 CopyOf->BackgroundColour = this->BackgroundColour;
1040 CopyOf->takesFocus = this->takesFocus;
1041 CopyOf->showBounds = this->showBounds;
1042 CopyOf->Visible = this->Visible;
1043 CopyOf->isClickable = this->isClickable;
1044 CopyOf->ToolTipText = this->ToolTipText;
1045 CopyOf->ToolTipFont = this->ToolTipFont;
1046 CopyOf->ToolTipBackground = this->ToolTipBackground;
1047 CopyOf->ToolTipBorders = this->ToolTipBorders;
1048
1049 for (auto &c : Controls)
1050 {
1051 if (c->canCopy)
1052 {
1053 c->copyTo(CopyOf);
1054 }
1055 }
1056}
1057
1058bool Control::eventIsWithin(const Event *e) const
1059{

Callers 1

initMethod · 0.80

Calls 1

copyToMethod · 0.45

Tested by

no test coverage detected