narikei / charger-information-for-mac Goto Github PK
View Code? Open in Web Editor NEWHome Page: https://apps.apple.com/app/wattageviewer/id1548099536
Home Page: https://apps.apple.com/app/wattageviewer/id1548099536
メニューバーにアプリケーションが表示されない。
Charger-Information-for-Mac v0.1.0 のインストーラでインストールしてアプリケーションを起動。
インストーラ v0.1.0 および、
GitHubリポジトリソース最新 commit df38b4d (v0.1.0) のnpm run start
で再現。
環境:
MacBookPro (13-inch, 2017) / macosx 10.14.6 Mojave
ソースから起動の場合、一瞬だけエラーダイアログが出現する。
app.dock.hide();
をコメントアウトして取得したエラーダイアログのスクリーンショット。
確認したところ、私の環境では ioreg -rn AppleSmartBattery
の出力に "AdapterDetails"が含まれていないようです。
アイコンクリックしてメニューを開く。
0〜5秒程度でメニューが勝手に閉じる。
「メニューが勝手に閉じない・少なくとも10秒程度は開いた状態を維持する」動きを想定していました。
定時間等で自動で閉じるべきかどうかは難しいところですが、最悪1秒待たずに閉じるのは、好ましくないと感じています。
とりあえずでupdateMenu();
をupdate
コールバック外に移動したところ、現象自体は起こらなくなるようです。ここでのMenu再構築の際に(electronから向こうのどこかの動作として)一旦閉じるようになっているのだと思います。ただこれでは状態表示の更新が反映されないようなので、もう一仕事とデザイン上の判断が必要そうです。
(閉じないように表示だけ更新する方法を見つける・Menuオープン中は更新しない・開き直す、などがあると思います。)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.