Skip to content

Commit

Permalink
TYPE_QUICK left-right refresh graph bug fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
harp077 committed May 4, 2023
1 parent 63f7973 commit 64e1bc9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/main/java/my/harp07/PjFrame.java
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public class PjFrame extends javax.swing.JFrame {
public static String currentLAF = "com.jtattoo.plaf.mint.MintLookAndFeel";
public static String currentTheme = "lib/themes/Default.theme";
public static List<String> tinyTemes = new ArrayList<>();
public static String zagolovok = "Pure Java Network Tools, v1.0.84, build 04-05-2023";
public static String zagolovok = "Pure Java Network Tools, v1.0.85, build 04-05-2023";

public PjFrame() {
initComponents();
Expand Down
8 changes: 4 additions & 4 deletions src/main/java/org/jrobin/mrtg/client/GraphFrame.java
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public class GraphFrame extends JFrame {
TYPE_CUSTOM = 6;

// YEAR BUG FIXED !!!!
static int START_YEAR = Year.now().getValue() - 1; //2022;
static int START_YEAR = Year.now().getValue(); // - 1; //2022;
static int END_YEAR = Year.now().getValue() + 1;//2032;

static Dimension GRAPH_SIZE = new Dimension(680, 480);
Expand Down Expand Up @@ -383,10 +383,10 @@ private void shift(boolean right) {
GregorianCalendar end = getDate(true);
switch (type) {
case TYPE_QUICK:
/*case TYPE_DAILY:
//case TYPE_DAILY:
start.add(Calendar.DAY_OF_MONTH, sign * 1);
end.add(Calendar.DAY_OF_MONTH, sign * 1);
break;*/
break;
case TYPE_WEEKLY:
start.add(Calendar.DAY_OF_MONTH, sign * 7);
end.add(Calendar.DAY_OF_MONTH, sign * 7);
Expand Down Expand Up @@ -476,7 +476,7 @@ private void fillYears(JComboBox combo) {
combo.insertItemAt("" + i, i - START_YEAR);
}
// YEAR BUG FIXED !!!!
combo.setSelectedIndex(1);
combo.setSelectedIndex(0);
}

private void fillHours(JComboBox combo) {
Expand Down

0 comments on commit 64e1bc9

Please sign in to comment.