Compare commits

..

No commits in common. "00182da1303beea51e4944aad0c69e0ede534981" and "92966570d82b79165572f60ffa9ed717bf91ce31" have entirely different histories.

3 changed files with 6 additions and 13 deletions

View File

@ -1,9 +1,4 @@
# EDMC_SpanshRouter # EDMC_SpanshRouter
## Note on norohind's fork
This is fork where I try to maintain working version of SpanshRouter
plugin for personal use with the latest version of EDMarketConnector.
I'm not trying to maintain README.md, CHANGELOG.md and auto-update system
of the plugin, at least now.
This plugin's purpose is to automatically copy to your clipboard the next waypoint on a route you planned using [Spansh](https://www.spansh.co.uk/plotter). This plugin's purpose is to automatically copy to your clipboard the next waypoint on a route you planned using [Spansh](https://www.spansh.co.uk/plotter).

View File

@ -4,9 +4,7 @@ import io
import json import json
import logging import logging
import os import os
import re
import subprocess import subprocess
import sys
import tkinter as tk import tkinter as tk
import tkinter.filedialog as filedialog import tkinter.filedialog as filedialog
import tkinter.messagebox as confirmDialog import tkinter.messagebox as confirmDialog
@ -16,10 +14,11 @@ from time import sleep
from tkinter import * from tkinter import *
import requests import requests
from config import appname from config import appname
from monitor import monitor from monitor import monitor
from . import AutoCompleter
from . import AutoCompleter, PlaceHolder from . import PlaceHolder
from .updater import SpanshUpdater from .updater import SpanshUpdater
# We need a name of plugin dir, not SpanshRouter.py dir # We need a name of plugin dir, not SpanshRouter.py dir
@ -161,7 +160,7 @@ class SpanshRouter():
self.csv_route_btn.grid_remove() self.csv_route_btn.grid_remove()
self.source_ac.grid() self.source_ac.grid()
# Prefill the "Source" entry with the current system # Prefill the "Source" entry with the current system
self.source_ac.set_text(monitor.state['SystemName'] if monitor.state['SystemName'] is not None else "Source System", monitor.state['SystemName'] is None) self.source_ac.set_text(monitor.system if monitor.system is not None else "Source System", monitor.system is None)
self.dest_ac.grid() self.dest_ac.grid()
self.range_entry.grid() self.range_entry.grid()
self.efficiency_slider.grid() self.efficiency_slider.grid()
@ -598,7 +597,7 @@ class SpanshRouter():
self.jumps_left += waypoint["jumps"] self.jumps_left += waypoint["jumps"]
self.enable_plot_gui(True) self.enable_plot_gui(True)
self.show_plot_gui(False) self.show_plot_gui(False)
self.offset = 1 if self.route[0][0] == monitor.state['SystemName'] else 0 self.offset = 1 if self.route[0][0] == monitor.system else 0
self.next_stop = self.route[self.offset][0] self.next_stop = self.route[self.offset][0]
self.copy_waypoint() self.copy_waypoint()
self.update_gui() self.update_gui()

View File

@ -51,7 +51,6 @@ def ask_for_update():
def plugin_app(parent): def plugin_app(parent):
global spansh_router global spansh_router
frame = spansh_router.init_gui(parent) spansh_router.init_gui(parent)
spansh_router.open_last_route() spansh_router.open_last_route()
parent.master.after_idle(ask_for_update) parent.master.after_idle(ask_for_update)
return frame