summaryrefslogtreecommitdiff
path: root/Gate.cpp
diff options
context:
space:
mode:
authorDaniel Jones <admin@danieljon.es>2020-06-24 15:25:12 +0930
committerDaniel Jones <admin@danieljon.es>2020-06-24 15:25:12 +0930
commit08ffc71b3b219c169af385ed9c47fae6535dcd67 (patch)
tree96d96919e5be79356496fff4ea2f479c52632ca2 /Gate.cpp
parentb7d79a8224a578ab5868eb2733bdf4a50db5e4f2 (diff)
downloadfoxlogicgates-08ffc71b3b219c169af385ed9c47fae6535dcd67.tar.gz
foxlogicgates-08ffc71b3b219c169af385ed9c47fae6535dcd67.zip
functionality: added ability to delete links. click on the input of the link you wish to delete and press the delete key.
Diffstat (limited to 'Gate.cpp')
-rw-r--r--Gate.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/Gate.cpp b/Gate.cpp
index a0ac6ea..70e55fe 100644
--- a/Gate.cpp
+++ b/Gate.cpp
@@ -40,7 +40,9 @@ Gate::remove_output_gate_id(int id)
{
if (id == (*g))
{
+ printf("%id = %d\n", id, *g);
output_gate_ids.erase(output_gate_ids.begin() + pos);
+ break;
}
pos++;
}
@@ -63,7 +65,7 @@ void Gate::update_state()
{
this->output_state = true;
}
- else if (input_gate1)
+ else
{
this->output_state = false;
}