summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.github/workflows/linux.yml6
-rw-r--r--libbridge/src/main/cpp/wallet2_api_c.cpp10
-rw-r--r--libbridge/src/main/cpp/wallet2_api_c.h2
3 files changed, 16 insertions, 2 deletions
diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml
index 0455f8f..0630b8b 100644
--- a/.github/workflows/linux.yml
+++ b/.github/workflows/linux.yml
@@ -1,7 +1,9 @@
name: Linux Release
run-name: Building monero_c for linux
-on: push
-
+on:
+ push:
+ tags:
+ - '*'
# cat envs.txt | sed 's/ //g' | sed 's/: /=/g' | grep -v '#' > .env
# export $(cat .env | xargs)
env:
diff --git a/libbridge/src/main/cpp/wallet2_api_c.cpp b/libbridge/src/main/cpp/wallet2_api_c.cpp
index 388c0b0..3e56263 100644
--- a/libbridge/src/main/cpp/wallet2_api_c.cpp
+++ b/libbridge/src/main/cpp/wallet2_api_c.cpp
@@ -499,6 +499,16 @@ void* MONERO_Coins_coin(void* coins_ptr, int index) {
Monero::Coins *coins = reinterpret_cast<Monero::Coins*>(coins_ptr);
return coins->coin(index);
}
+
+int MONERO_Coins_getAll_size(void* coins_ptr) {
+ Monero::Coins *coins = reinterpret_cast<Monero::Coins*>(coins_ptr);
+ return coins->getAll().size();
+}
+void* MONERO_Coins_getAll_byIndex(void* coins_ptr, int index) {
+ Monero::Coins *coins = reinterpret_cast<Monero::Coins*>(coins_ptr);
+ return coins->getAll()[index];
+}
+
// virtual std::vector<CoinsInfo*> getAll() const = 0;
// virtual void refresh() = 0;
void MONERO_Coins_refresh(void* coins_ptr) {
diff --git a/libbridge/src/main/cpp/wallet2_api_c.h b/libbridge/src/main/cpp/wallet2_api_c.h
index 53b75f2..27aa2e3 100644
--- a/libbridge/src/main/cpp/wallet2_api_c.h
+++ b/libbridge/src/main/cpp/wallet2_api_c.h
@@ -304,6 +304,8 @@ int MONERO_Coins_count(void* coins_ptr);
// virtual CoinsInfo * coin(int index) const = 0;
void* MONERO_Coins_coin(void* coins_ptr, int index);
// virtual std::vector<CoinsInfo*> getAll() const = 0;
+int MONERO_Coins_getAll_size(void* coins_ptr);
+void* MONERO_Coins_getAll_byIndex(void* coins_ptr, int index);
// virtual void refresh() = 0;
void MONERO_Coins_refresh(void* coins_ptr);
// virtual void setFrozen(std::string public_key) = 0;