Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
55ac08b
Scheduling: schedule and project models, working calendars, critical …
shai-almog Nov 11, 2026
4c87293
Scheduler: day, week, month, agenda and resource views over a schedul…
shai-almog Nov 11, 2026
4a48b88
Gantt: task table, bars, links, drag editing and resource load over a…
shai-almog Nov 11, 2026
26b11fb
Scheduling: tests for the memory and calendar schedule models
shai-almog Nov 11, 2026
feb7677
Picker: Material 3 date and time pickers, chosen by the pickerStyle t…
shai-almog Nov 11, 2026
15c904a
Themes: scheduler, Gantt, Material picker and Calendar styles; today …
shai-almog Nov 11, 2026
c51a42f
SchedulePrinter: a scheduler or a Gantt chart on pages, as images, a …
shai-almog Nov 11, 2026
f7fd6c1
Slate: the board and the provider's day and week are the framework's …
shai-almog Nov 11, 2026
07f7796
Docs: scheduling and Gantt chapter, Material pickers, runnable snippets
shai-almog Nov 11, 2026
ed566ca
Screenshot tests: scheduler week, month and resource views, Gantt, Ma…
shai-almog Nov 11, 2026
f2b651f
Scheduling: static analysis at zero, headers on the screenshot tests
shai-almog Nov 11, 2026
5608e84
Scheduler view menu and Material picker dialog never become OS windows
shai-almog Nov 11, 2026
86ddca2
Scheduling, Gantt and Material pickers: red-team round one
shai-almog Nov 11, 2026
cbded93
Scheduling, Gantt and Material pickers: red-team round two
shai-almog Nov 11, 2026
d6b6a6f
Scheduling, Gantt and Material pickers: red-team round three
shai-almog Nov 11, 2026
fb6053d
Scheduling, Gantt and Material pickers: red-team round four
shai-almog Nov 11, 2026
6dfb9dd
Scheduling and Material pickers: red-team round five
shai-almog Nov 11, 2026
afdb3a4
Scheduling, Gantt and Material pickers: pointer feedback, motion and …
shai-almog Nov 11, 2026
1bdd48d
Material time picker: one aligned row, a real typed mode, dark defaults
shai-almog Nov 12, 2026
6525ba3
Scheduling and pickers: dark defaults survive a theme refresh, CI fix…
shai-almog Nov 12, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
/*
* Copyright (c) 2026, Codename One and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Codename One designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Codename One through http://www.codenameone.com/ if you
* need additional information or have any questions.
*/
package com.codename1.scheduling;

import java.util.ArrayList;
import java.util.List;

/// The listener list and the refusals every read-only model shares.
///
/// A subclass has to supply `getResources` and `getItems`. Every edit is
/// refused until the matching method is overridden.
public abstract class AbstractScheduleModel implements ScheduleModel {
private final List<ScheduleChangeListener> listeners = new ArrayList<ScheduleChangeListener>();

@Override
public void setVisibleRange(long from, long to) {
}

@Override
public boolean updateItem(ScheduleItem item, long start, long end, String resourceId) {
return false;
}

@Override
public ScheduleItem createItem(long start, long end, String resourceId) {
return null;
}

@Override
public boolean removeItem(ScheduleItem item) {
return false;
}

@Override
public void addChangeListener(ScheduleChangeListener l) {
if (l != null && !listeners.contains(l)) {
listeners.add(l);
}
}

@Override
public void removeChangeListener(ScheduleChangeListener l) {
listeners.remove(l);
}

/// Tells every listener the model changed.
protected void fireChanged() {
// A listener may remove itself while it is told.
for (int i = listeners.size() - 1; i >= 0; i--) {
if (i < listeners.size()) {
listeners.get(i).scheduleChanged(this);
}
}
}
}
Loading
Loading