Horizon
Loading...
Searching...
No Matches
src
core
tools
tool_place_via.hpp
1
#pragma once
2
#include "core/tool.hpp"
3
#include "tool_place_junction.hpp"
4
#include "board/board_junction.hpp"
5
#include <forward_list>
6
7
namespace
horizon {
8
9
class
ToolPlaceVia
:
public
ToolPlaceJunctionT
<class BoardJunction> {
10
public
:
11
using
ToolPlaceJunctionT
<
BoardJunction
>
::ToolPlaceJunctionT
;
12
bool
can_begin
()
override
;
13
std::set<InToolActionID> get_actions()
const override
14
{
15
using
I = InToolActionID;
16
return
{
17
I::LMB, I::CANCEL, I::RMB, I::EDIT, I::SELECT_VIA_DEFINITION,
18
};
19
}
20
21
protected
:
22
void
insert_junction()
override
;
23
void
create_attached()
override
;
24
void
delete_attached()
override
;
25
bool
begin_attached()
override
;
26
void
finish()
override
;
27
bool
update_attached(
const
ToolArgs
&args)
override
;
28
class
Via
*via =
nullptr
;
29
class
Net
*net =
nullptr
;
30
std::set<UUID> nets;
31
32
std::forward_list<class Via *> vias_placed;
33
const
class
ViaDefinition
*via_definition =
nullptr
;
34
35
private
:
36
const
class
BoardRules
*rules =
nullptr
;
37
void
update_tip();
38
void
update_via();
39
};
40
}
// namespace horizon
horizon::BoardJunction
Definition
board_junction.hpp:6
horizon::BoardRules
Definition
board_rules.hpp:28
horizon::Net
Definition
net.hpp:11
horizon::ToolArgs
This is what a Tool receives when the user did something.
Definition
tool_pub.hpp:23
horizon::ToolPlaceJunctionT
Definition
tool_place_junction.hpp:57
horizon::ToolPlaceVia
Definition
tool_place_via.hpp:9
horizon::ToolPlaceVia::can_begin
bool can_begin() override
Definition
tool_place_via.cpp:12
horizon::ViaDefinition
Definition
via_definition.hpp:7
horizon::Via
Definition
via.hpp:12
Generated by
1.15.0