├── .github ├── ISSUE_TEMPLATE │ ├── bug_report.md │ ├── config.yml │ └── feature_request.md ├── README.md └── pull_request_template.md ├── .gitignore ├── .vscode └── launch.json ├── CHANGELOG.md ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── analysis_options.yaml ├── lib ├── dahlia_backend.dart └── src │ ├── api │ ├── data_provider.dart │ ├── device_info.dart │ ├── system_calls.dart │ ├── time_date_manager.dart │ └── wm │ │ ├── hierarchy.dart │ │ ├── properties.dart │ │ └── wm.dart │ ├── data │ ├── data_management.dart │ └── feature_flags.dart │ ├── vars │ └── application.dart │ └── widgets │ ├── acrylic.dart │ ├── blur.dart │ ├── box_container.dart │ └── error_window.dart ├── pubspec.yaml └── test └── dahlia_backend_test.dart /.github/ISSUE_TEMPLATE/bug_report.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Bug report 3 | about: Create a report to help us improve the desktop 4 | title: '' 5 | labels: '' 6 | assignees: '' 7 | 8 | --- 9 | 10 | **Describe the bug** 11 | A clear and concise description of what the bug is. 12 | 13 | **What kind of a bug is it?** 14 | Describe what kind of a bug it is. [e.g. Typo, visual, application bug, OS bug] 15 | 16 | **To Reproduce** 17 | Steps to reproduce the behavior: 18 | 1. Go to '...' 19 | 2. Click on '....' 20 | 3. Scroll down to '....' 21 | 4. See error 22 | 23 | **Expected behavior** 24 | A clear and concise description of what you expected to happen. 25 | 26 | **Screenshots** 27 | If applicable, add screenshots to help explain your problem. 28 | 29 | **Desktop (please complete the following information):** 30 | - OS: [e.g. dahliaOS Linux, dahliaOS Zircon] 31 | - Device: [e.g. MacbookPro9,1, QEMU] 32 | 33 | **Smartphone (please complete the following information):** 34 | - Device: [e.g. iPhone6] 35 | - OS: [e.g. Android, dahliaOS Zircon, dahliaOS Linux] 36 | - Execution Method: [e.g. ADB, Zircon tool] 37 | 38 | **dahliaOS build version** 39 | Write what version of dahliaOS you were using. 40 | 41 | **Additional context** 42 | Add any other context about the problem here. 43 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/config.yml: -------------------------------------------------------------------------------- 1 | blank_issues_enabled: false 2 | contact_links: 3 | - name: Help 4 | url: https://dahliaos.io/discord 5 | about: 'If you have a question or need help, join our Discord!' 6 | - name: Documentation issue 7 | url: https://github.com/dahliaos/documentation 8 | about: 'For documentation issues, suggest changes on our documentation repository.' 9 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature_request.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Feature request 3 | about: Suggest an idea for Pangolin 4 | title: '' 5 | labels: '' 6 | assignees: '' 7 | 8 | --- 9 | 10 | **Is your feature request related to a problem? Please describe.** 11 | A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] 12 | 13 | **Describe the solution you'd like** 14 | A clear and concise description of what you want to happen. 15 | 16 | **Describe alternatives you've considered** 17 | A clear and concise description of any alternative solutions or features you've considered. 18 | 19 | **For which platform is this feature request?** 20 | - Platform: [Linux, Zircon or Mobile] 21 | 22 | **Do you have an idea of how we would add it?** 23 | If you know how we would approach adding this feature, tell us how. 24 | 25 | **Why should we add it?** 26 | Explain to use how our project can benefit of your feature request. 27 | 28 | **Additional context** 29 | Add any other context or screenshots about the feature request here. -------------------------------------------------------------------------------- /.github/README.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 |
5 | Website ● 6 | Discord ● 7 | Releases ● 8 | Donate ● 9 | Documentation 10 | 11 | # backend 12 | 13 | 14 | - **Backend** for the Pangolin Desktop 15 | 16 | ## Contribute 17 | 18 | If you're wondering how to contribute to the project, please refer to [CONTRIBUTING.md](../CONTRIBUTING.md) 19 | 20 | ## License 21 | 22 |
23 |
25 |
26 | Copyright @ 2019-2021 The dahliaOS Authors contact@dahliaos.io
27 |
28 | This project is licensed under the [Apache 2.0 license](../LICENSE)
29 |
--------------------------------------------------------------------------------
/.github/pull_request_template.md:
--------------------------------------------------------------------------------
1 | # Pull request template
2 |
3 | * Please make sure you read and fill this template out entirely
4 | * PRs that don't have the template filled out will be ignored
5 |
6 | ## Description
7 |
8 | - Please include a summary of the change and which issue is fixed
9 | - Please also include relevant motivation and context (Why is this change required? What problem does it solve?)
10 | - List any dependencies that are required for this change
11 | - If it fixes an open issue, plase link to the issue here
12 |
13 | Fixes #(issue)
14 |
15 | ## Screenshots (if appropriate):
16 |
17 | ## Type of change
18 |
19 | Please tick the relevant option by putting an X inside the bracket
20 |
21 | - [ ] Bug fix (non-breaking change which fixes an issue)
22 | - [ ] New feature (non-breaking change which adds functionality)
23 | - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
24 | - [ ] This change requires a documentation update
25 |
26 | ## Checklist:
27 |
28 | - [ ] My code follows the guidelines of this project
29 | - [ ] I have performed a self-review of my own code
30 | - [ ] I have commented my code, particularly in hard-to-understand areas
31 | - [ ] I have made corresponding changes to the documentation
32 | - [ ] My changes generate no new warnings
33 | - [ ] All current GitHub actions pass
34 | - [ ] Any dependent changes have been merged and published in downstream modules
35 | - [ ] I have checked my code and corrected any misspellings
36 | - [ ] I have read the [CONTRIBUTING](../CONTRIBUTING.md) document
37 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Files and directories created by pub
2 | .dart_tool/
3 | .packages
4 |
5 | # Omit commiting pubspec.lock for library packages:
6 | # https://dart.dev/guides/libraries/private-files#pubspeclock
7 | pubspec.lock
8 |
9 | # Conventional directory for build outputs
10 | build/
11 |
12 | # Directory created by dartdoc
13 | doc/api/
14 |
15 | # Flutter/Dart/Pub related
16 | **/doc/api/
17 | **/ios/Flutter/.last_build_id
18 | .dart_tool/
19 | .flutter-plugins
20 | .flutter-plugins-dependencies
21 | .packages
22 | .pub-cache/
23 | .pub/
24 | /build/
--------------------------------------------------------------------------------
/.vscode/launch.json:
--------------------------------------------------------------------------------
1 | {
2 | // Use IntelliSense to learn about possible attributes.
3 | // Hover to view descriptions of existing attributes.
4 | // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
5 | "version": "0.2.0",
6 | "configurations": [
7 | {
8 | "name": "dahlia_backend",
9 | "request": "launch",
10 | "type": "dart",
11 | "program": "../lib/main.dart",
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/CHANGELOG.md:
--------------------------------------------------------------------------------
1 | ## 1.0.0
2 |
3 | - Initial version, created by Stagehand
4 |
--------------------------------------------------------------------------------
/CODE_OF_CONDUCT.md:
--------------------------------------------------------------------------------
1 | # dahliaOS Code of Conduct
2 |
3 | The dahliaOS team is committed to preserving and fostering a
4 | diverse, welcoming community. Below is our community code of conduct, which
5 | applies to our repos and organizations, issue trackers, Discord servers,
6 | blog content, and any other dahliaOS-supported communication group, as
7 | well as any private communication initiated in the context of these
8 | spaces. This code of conduct must be followed by everyone contributing to
9 | the dahliaOS project, regardless of affiliation or position.
10 |
11 | Simply put, community discussions should be
12 |
13 | * respectful and kind;
14 | * about software;
15 | * about features and code, not the individuals involved.
16 |
17 | ## Be respectful and constructive.
18 |
19 | Treat everyone with respect. Build on each other's ideas. Each of us has the
20 | right to enjoy our experience and participate without fear of harassment,
21 | discrimination, or condescension, whether blatant or subtle. Remember that
22 | dahliaOS is a geographically distributed team and that you may not be
23 | communicating with someone in their primary language. We all get frustrated
24 | when working on hard problems, but we cannot allow that frustration to turn
25 | into personal attacks.
26 |
27 | ## Speak up if you see or hear something.
28 |
29 | You are empowered to politely engage when you feel that you or others are
30 | disrespected. The person making you feel uncomfortable may not be aware of what
31 | they are doing - politely bringing their behavior to their attention is
32 | encouraged.
33 |
34 | If you are uncomfortable speaking up, or feel that your concerns are not being
35 | duly considered, you can email the Project Integrity team at integrity@dahliaos.io to request involvement from a moderator. All
36 | concerns shared with community managers will be kept confidential, but you may
37 | also submit an anonymous report [here](dahlia-os.github.io/anon).
38 | Please note that without a way to contact you, an anonymous report may be
39 | difficult to act on. You may also create a throwaway account to report. In
40 | cases where a public response is deemed necessary, the identities of victims
41 | and reporters will remain confidential unless those individuals instruct us
42 | otherwise.
43 |
44 | While all reports will be taken seriously, the Project Integrity Team may
45 | not act on complaints that they feel are not violations of this code of
46 | conduct.
47 |
48 | ## We will not tolerate harassment of any kind, including but not limited to:
49 |
50 | * Harassing comments
51 | * Intimidation
52 | * Arguing over subjective preference, e.g. text editors, nationality, religion, etc.
53 | * Encouraging a person to engage in self-harm.
54 | * Sustained disruption or derailing of threads, channels, lists, etc.
55 | * Offensive or violent comments, jokes or otherwise
56 | * Inappropriate sexual content
57 | * Unwelcome sexual or otherwise aggressive attention
58 | * Continued one-on-one communication after requests to cease
59 | * Distribution or threat of distribution of people's personally identifying
60 | information, AKA “doxing”
61 |
62 | ## Consequences for failing to comply with this policy
63 |
64 | Consequences for failing to comply with this policy may include, at the sole
65 | discretion of the dahliaOS Project Integrity Team:
66 |
67 | * a request for an apology;
68 | * a private or public warning or reprimand;
69 | * a temporary ban from the Discord server, blog, dahlia-os repository or
70 | organization, or other dahliaOS-supported communication group, including
71 | loss of committer status;
72 | * a permanent ban from any of the above, or from all current and future
73 | dahliaOS-supported communities, including loss of
74 | committer status.
75 |
76 | Participants warned to stop any harassing behavior are expected to comply
77 | immediately; failure to do so will result in an escalation of consequences.
78 |
79 | ## Acknowledgements
80 |
81 | This Code of Conduct is adapted from the Chromium Project Code of Conduct.
82 |
83 | ## License
84 |
85 | This Code of Conduct is available for reuse under the Creative Commons Zero
86 | (CC0) license.
87 |
--------------------------------------------------------------------------------
/CONTRIBUTING.md:
--------------------------------------------------------------------------------
1 | # Contributing
2 |
3 | dahliaOS is open to contributions. Any contribution is appreciated, whether it is a documentation update, localization, bug fix or a new feature. Anyone can contribute as long as they follow this guideline and obey the dahliaOS Code of Conduct.
4 | To make sure your contributions go as smooth as possible, here are all the things you need to know.
5 |
6 | ## Table of contents
7 |
8 | 1. **[Communication](#communication)**
9 | 1. **[Code of Conduct](#code-of-conduct)**
10 | 1. **[Contribute](#contribute)**
11 | 1. [Bug report](#bug-report)
12 | 1. [Before submitting a bug report](#before-submitting-a-bug-report)
13 | 1. [Writing a good bug report](#writing-a-good-bug-report)
14 | 1. [Submitting a bug report](#submitting-a-bug-report)
15 | 1. [Feature request](#feature-request)
16 | 1. [Before submitting a feature request](#before-submitting-a-feature-request)
17 | 1. [Submitting a feature request](#submitting-a-feature-request)
18 | 1. [Pull request](#pull-request)
19 | 1. [Before submitting a pull request](#before-submitting-a-pull-request)
20 | 1. [How to submit a proper pull request](#how-to-submit-a-proper-pull-request)
21 | 1. [After submitting a pull request](#after-submitting-a-pull-request)
22 | 1. [Translations](#translations)
23 | 1. [Before making a translation](#before-making-a-translation)
24 | 1. [How to translate](#how-to-translate)
25 | 1. [Code contributions](#code-contributions)
26 | 1. [First code contribution](#first-code-contribution)
27 | 1. [Design contributions](#design-contributions)
28 | 1. [Financial contributions](#financial-contributions)
29 | 1. [Finding tasks](#finding-tasks)
30 | 1. **[License](#license)**
31 |
32 | ## Communication
33 |
34 | Communication with core dahliaOS development team is crucial for any successful participation in dahliaOS development. There are several methods to communicate with the core team:
35 |
36 | * [Discord](https://dahliaos.io/discord) - We use Discord for pinging people, sharing updates, quick and informal discussions, questions and answers, etc. It is OK to discuss your contribution, planned contribution, development idea, localization, documentation updates and similar topics in this server. Anyone interested in the project is welcome to join our Discord server and hang around.
37 | * [Telegram](https://dahliaos.io/telegram) - Same as Discord.
38 | * [Issues / pull requests](https://github.com/dahliaOS) - Most of the work is discussed here, including upgrades and proposals for upgrades, bug fixing and feature requests. For any of these, open an issue in the corresponding repository. If you are proposing code change, open a pull request.
39 |
40 | Each of them is intended for an specific purpose. Please understand that you may be redirected to some other mean if the communication you intend to have is considered to fit better elsewhere.
41 |
42 | ## Code of Conduct
43 |
44 | This project and everyone participating in it is governed by our Code of Conduct and no one is exempt.
45 | By participating, you are expected to respect and value this code.
46 | dahliaOS Code of Conduct can be found [here](CODE_OF_CONDUCT.md).
47 | If you notice any unacceptable behaviour, we encourage you to report it to integrity@dahliaos.io
48 |
49 | ## Contribute
50 |
51 | In this document we've explained how you can contribute to our project, if you'd like to help out in a different way that is not documented here, you're always free to join our Discord and discuss other options you have in mind with our team.
52 |
53 | You can contribute to the project by:
54 |
55 | * Reporting a bug.
56 | * Proposing new features.
57 | * Translating to your native language.
58 | * Submitting a fix.
59 | * Discussing the current state of code.
60 | * Becoming a maintainer.
61 | * Making a financial contribution.
62 |
63 | ### Bug report
64 |
65 | If you've experienced a bug and you'd like to report it, we highly recommend that you read [Before submitting a bug report](#before-submitting-a-bug-report) and [Writing a good bug report](#writing-a-good-bug-report) first, and that you also use our issue template.
66 |
67 | There are 2 ways you can report a bug, either in our Discord server by **opening a ticket** or by **creating an issue** using the **bug report template** on GitHub.
68 |
69 | #### Before submitting a bug report
70 |
71 | Before submitting a bug report, there are a few things you need to take in consideration:
72 |
73 | * Do a bit of research and check if a similar bug has already been reported.
74 | * If it has been reported already, add a comment to the existing one instead of submitting a new one.
75 |
76 | #### Writing a good bug report
77 |
78 | We have a few short tips for you on how to properly write a bug report so the developers can understand it better:
79 |
80 | * Use a clear and descriptive title for the issue.
81 | * Describe the steps to reproduce the bug.
82 | * Describe what behaviour you observed after the bug occurred.
83 | * Explain what behaviour you expected to see instead and why.
84 | * If the problem wasn't triggered by a specific action, describe what you were doing before it happened.
85 | * Include screenshots of the bug.
86 | * Write what version of dahliaOS you were using.
87 |
88 | And the most important of all make sure to fill in as many fields as possible in our bug report template.
89 |
90 | #### Submitting a bug report
91 |
92 | * **GitHub**:
93 | 1. Click the **Issues** tab
94 | 1. Click **New issue**
95 | 1. Select the **Bug report** template
96 | 1. Fill in the fields
97 | * **Discord**:
98 | 1. Go to the **#bug-report** channel
99 | 1. Open a **ticket** and copy the **form**
100 | 1. Paste and fill in the form
101 |
102 | ### Feature request
103 |
104 | If you'd like to see something added to dahliaOS, we highly recommend that you read [Before submitting a feature request](#before-submitting-a-feature-request) and [Submitting a feature request](#submitting-a-feature-request) first, and that you also use our feature request template.
105 |
106 | To submit a feature request, **create an issue** using the **feature request template** on GitHub.
107 |
108 | #### Before submitting a feature request
109 |
110 | Before submitting a feature request, here are a few things you need to know:
111 |
112 | * Make sure the feature isn't already added.
113 | * Don't hesitate to express your knowledge.
114 | * Write a clear and descriptive title for the request.
115 | * Explain how the project could benefit of your request.
116 |
117 | #### Submitting a feature request
118 |
119 | * **GitHub**:
120 | 1. Click the **Issues** tab
121 | 1. Click **New issue**
122 | 1. Select the **Feature request** template
123 | 1. Fill in the fields
124 |
125 | ### Pull request
126 |
127 | Pull requests to our repositories are always welcome and can be a quick way to get your fix or improvement slated for the next release. In general, pull requests should:
128 |
129 | * Fix an existing issue or add a new feature.
130 | * Be accompanied by a complete pull request template (loaded automatically when a pull request is created).
131 |
132 | For changes that address core functionality or would require breaking changes (e.g. a major release), it's best to open an issue to discuss your proposal first. This is not required but can save time creating and reviewing changes.
133 |
134 | #### Before submitting a pull request
135 |
136 | To make sure that the pull request you want to submit is up to our standards, we've written a few dos and don'ts:
137 |
138 | **Dos**:
139 |
140 | * Provide a meaningful commit message.
141 | * The first line of the commit message should have the format "Category: Brief description of what's being changed". The "category" can be a subdirectory, but also something like "POSIX compliance" or "ClassName".
142 | * Write your commit messages in proper English, with care and punctuation.
143 | * Use the present tense ("Add feature" not "Added feature")
144 | * Use the imperative mood ("Move cursor to..." not "Moves cursor to...")
145 | * Limit the first line to 72 characters or less
146 | * You may want to create a topic branch for larger contributions.
147 | * Split your changes into separate commits.
148 |
149 | **Don'ts**:
150 |
151 | * Touch anything outside the stated scope of the pull request.
152 | * Use weasel-words like "refactor" or "fix" to avoid explaining what's being changed.
153 |
154 | #### How to submit a proper pull request
155 |
156 | 1. **Fork** the repository to your own GitHub account
157 | 1. **Clone** the project to your machine
158 | 1. Make your **changes**
159 | 1. **Push** changes to your fork
160 | 1. **Open a pull request** in our repository and **fill** in the pull request template
161 |
162 | #### After submitting a pull request
163 |
164 | We kindly ask everyone who has submitted a pull request to be patient, we notice every new pull request so don't worry about it being ignored, we'll be on it as soon as possible.
165 |
166 | ### Translations
167 |
168 | We aim to provide our software in as many languages as possible so everyone could experience it in their own native language.
169 | For submitting translations, we use Crowdin so please do not edit the files found in the repositories.
170 | If you're interesting in translating our project, click [here](https://translate.dahliaos.io).
171 | **Note**: If the language you're looking to translate to is not added, let us know and we'll add it right away.
172 |
173 | #### Before making a translation
174 |
175 | Before making a translation, please make sure that:
176 |
177 | * You're fluent in the language you're translating to.
178 | * You pay close attention to grammar.
179 | * You read the context (comments) some strings have.
180 | * You used the same punctuation as the source strings.
181 |
182 | #### How to translate
183 |
184 | 1. Create a **Crowdin** account (if you already don't have one)
185 | 1. Join our **workspace**
186 | 1. Pick a **project** to translate
187 | 1. Apply translations to the available strings
188 |
189 | ### Code contributions
190 |
191 | To make sure that the code you want to contribute is up to our standards, we've written a few dos and don'ts:
192 |
193 | **Dos**:
194 |
195 | * Choose expressive variable, function and class names, make it as obvious as possible of what the code is doing.
196 |
197 | **Don'ts**:
198 |
199 | * Submit code that's incompatible with the project license (Apache 2.0).
200 | * Include commented-out code.
201 |
202 | #### First code contribution
203 |
204 | If you're not yet familiar with the development of dahliaOS, you can tackle tasks labeled with the "good first issue" label on our GitHub as they are more suited for newcomers looking to gain some experience.
205 |
206 | ### Design contributions
207 |
208 | Apart from code contributions, we also accept various kinds of design contributions.
209 |
210 | Here are a few repositories where you can contribute designs:
211 |
212 | * [wallpapers](https://github.com/dahliaos/wallpapers)
213 | * Contribute your own wallpapers made for dahliaOS.
214 | * [icons](https://github.com/dahliaos/icons)
215 | * Contribute/propose new or modified icons for dahliaOS.
216 | * [brand](https://github.com/dahliaos/brand)
217 | * Contribute/propose new or modified logos of our brand.
218 | * [press-kit](https://github.com/dahliaos/press-kit)
219 | * Contribute mockups, screenshots, graphics, marketing material and such for dahliaOS.
220 |
221 | We love seeing concepts and designs, feel free to share them with us on our social media!
222 |
223 | ### Financial contributions
224 |
225 | dahliaOS is an Apache 2.0-licensed free open source project that financially relies mainly on donations.
226 | Donations helps us pay the bills (web hosts, domains, software/hardware, etc.) to keep this project on its feet as long as possible.
227 | If you're interested in sending a donation to dahliaOS, click [here](https://dahliaos.io/donate) to find out where you can do so. Another way you can find donation links is by clicking the Sponsors button in most of our GitHub repositories.
228 |
229 | ### Finding tasks
230 |
231 | If you're interested in contributing to dahliaOS but don't know what you can assist us with, you can find available tasks by:
232 |
233 | * Peeking at GitHub issues / projects
234 | * Asking in our Discord or Telegram
235 |
236 | ## License
237 |
238 | By contributing to dahliaOS, you agree that your contributions will be licensed under the [Apache 2.0](LICENSE) license.
239 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | Apache License
2 | Version 2.0, January 2004
3 | http://www.apache.org/licenses/
4 |
5 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6 |
7 | 1. Definitions.
8 |
9 | "License" shall mean the terms and conditions for use, reproduction,
10 | and distribution as defined by Sections 1 through 9 of this document.
11 |
12 | "Licensor" shall mean the copyright owner or entity authorized by
13 | the copyright owner that is granting the License.
14 |
15 | "Legal Entity" shall mean the union of the acting entity and all
16 | other entities that control, are controlled by, or are under common
17 | control with that entity. For the purposes of this definition,
18 | "control" means (i) the power, direct or indirect, to cause the
19 | direction or management of such entity, whether by contract or
20 | otherwise, or (ii) ownership of fifty percent (50%) or more of the
21 | outstanding shares, or (iii) beneficial ownership of such entity.
22 |
23 | "You" (or "Your") shall mean an individual or Legal Entity
24 | exercising permissions granted by this License.
25 |
26 | "Source" form shall mean the preferred form for making modifications,
27 | including but not limited to software source code, documentation
28 | source, and configuration files.
29 |
30 | "Object" form shall mean any form resulting from mechanical
31 | transformation or translation of a Source form, including but
32 | not limited to compiled object code, generated documentation,
33 | and conversions to other media types.
34 |
35 | "Work" shall mean the work of authorship, whether in Source or
36 | Object form, made available under the License, as indicated by a
37 | copyright notice that is included in or attached to the work
38 | (an example is provided in the Appendix below).
39 |
40 | "Derivative Works" shall mean any work, whether in Source or Object
41 | form, that is based on (or derived from) the Work and for which the
42 | editorial revisions, annotations, elaborations, or other modifications
43 | represent, as a whole, an original work of authorship. For the purposes
44 | of this License, Derivative Works shall not include works that remain
45 | separable from, or merely link (or bind by name) to the interfaces of,
46 | the Work and Derivative Works thereof.
47 |
48 | "Contribution" shall mean any work of authorship, including
49 | the original version of the Work and any modifications or additions
50 | to that Work or Derivative Works thereof, that is intentionally
51 | submitted to Licensor for inclusion in the Work by the copyright owner
52 | or by an individual or Legal Entity authorized to submit on behalf of
53 | the copyright owner. For the purposes of this definition, "submitted"
54 | means any form of electronic, verbal, or written communication sent
55 | to the Licensor or its representatives, including but not limited to
56 | communication on electronic mailing lists, source code control systems,
57 | and issue tracking systems that are managed by, or on behalf of, the
58 | Licensor for the purpose of discussing and improving the Work, but
59 | excluding communication that is conspicuously marked or otherwise
60 | designated in writing by the copyright owner as "Not a Contribution."
61 |
62 | "Contributor" shall mean Licensor and any individual or Legal Entity
63 | on behalf of whom a Contribution has been received by Licensor and
64 | subsequently incorporated within the Work.
65 |
66 | 2. Grant of Copyright License. Subject to the terms and conditions of
67 | this License, each Contributor hereby grants to You a perpetual,
68 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69 | copyright license to reproduce, prepare Derivative Works of,
70 | publicly display, publicly perform, sublicense, and distribute the
71 | Work and such Derivative Works in Source or Object form.
72 |
73 | 3. Grant of Patent License. Subject to the terms and conditions of
74 | this License, each Contributor hereby grants to You a perpetual,
75 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76 | (except as stated in this section) patent license to make, have made,
77 | use, offer to sell, sell, import, and otherwise transfer the Work,
78 | where such license applies only to those patent claims licensable
79 | by such Contributor that are necessarily infringed by their
80 | Contribution(s) alone or by combination of their Contribution(s)
81 | with the Work to which such Contribution(s) was submitted. If You
82 | institute patent litigation against any entity (including a
83 | cross-claim or counterclaim in a lawsuit) alleging that the Work
84 | or a Contribution incorporated within the Work constitutes direct
85 | or contributory patent infringement, then any patent licenses
86 | granted to You under this License for that Work shall terminate
87 | as of the date such litigation is filed.
88 |
89 | 4. Redistribution. You may reproduce and distribute copies of the
90 | Work or Derivative Works thereof in any medium, with or without
91 | modifications, and in Source or Object form, provided that You
92 | meet the following conditions:
93 |
94 | (a) You must give any other recipients of the Work or
95 | Derivative Works a copy of this License; and
96 |
97 | (b) You must cause any modified files to carry prominent notices
98 | stating that You changed the files; and
99 |
100 | (c) You must retain, in the Source form of any Derivative Works
101 | that You distribute, all copyright, patent, trademark, and
102 | attribution notices from the Source form of the Work,
103 | excluding those notices that do not pertain to any part of
104 | the Derivative Works; and
105 |
106 | (d) If the Work includes a "NOTICE" text file as part of its
107 | distribution, then any Derivative Works that You distribute must
108 | include a readable copy of the attribution notices contained
109 | within such NOTICE file, excluding those notices that do not
110 | pertain to any part of the Derivative Works, in at least one
111 | of the following places: within a NOTICE text file distributed
112 | as part of the Derivative Works; within the Source form or
113 | documentation, if provided along with the Derivative Works; or,
114 | within a display generated by the Derivative Works, if and
115 | wherever such third-party notices normally appear. The contents
116 | of the NOTICE file are for informational purposes only and
117 | do not modify the License. You may add Your own attribution
118 | notices within Derivative Works that You distribute, alongside
119 | or as an addendum to the NOTICE text from the Work, provided
120 | that such additional attribution notices cannot be construed
121 | as modifying the License.
122 |
123 | You may add Your own copyright statement to Your modifications and
124 | may provide additional or different license terms and conditions
125 | for use, reproduction, or distribution of Your modifications, or
126 | for any such Derivative Works as a whole, provided Your use,
127 | reproduction, and distribution of the Work otherwise complies with
128 | the conditions stated in this License.
129 |
130 | 5. Submission of Contributions. Unless You explicitly state otherwise,
131 | any Contribution intentionally submitted for inclusion in the Work
132 | by You to the Licensor shall be under the terms and conditions of
133 | this License, without any additional terms or conditions.
134 | Notwithstanding the above, nothing herein shall supersede or modify
135 | the terms of any separate license agreement you may have executed
136 | with Licensor regarding such Contributions.
137 |
138 | 6. Trademarks. This License does not grant permission to use the trade
139 | names, trademarks, service marks, or product names of the Licensor,
140 | except as required for reasonable and customary use in describing the
141 | origin of the Work and reproducing the content of the NOTICE file.
142 |
143 | 7. Disclaimer of Warranty. Unless required by applicable law or
144 | agreed to in writing, Licensor provides the Work (and each
145 | Contributor provides its Contributions) on an "AS IS" BASIS,
146 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147 | implied, including, without limitation, any warranties or conditions
148 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149 | PARTICULAR PURPOSE. You are solely responsible for determining the
150 | appropriateness of using or redistributing the Work and assume any
151 | risks associated with Your exercise of permissions under this License.
152 |
153 | 8. Limitation of Liability. In no event and under no legal theory,
154 | whether in tort (including negligence), contract, or otherwise,
155 | unless required by applicable law (such as deliberate and grossly
156 | negligent acts) or agreed to in writing, shall any Contributor be
157 | liable to You for damages, including any direct, indirect, special,
158 | incidental, or consequential damages of any character arising as a
159 | result of this License or out of the use or inability to use the
160 | Work (including but not limited to damages for loss of goodwill,
161 | work stoppage, computer failure or malfunction, or any and all
162 | other commercial damages or losses), even if such Contributor
163 | has been advised of the possibility of such damages.
164 |
165 | 9. Accepting Warranty or Additional Liability. While redistributing
166 | the Work or Derivative Works thereof, You may choose to offer,
167 | and charge a fee for, acceptance of support, warranty, indemnity,
168 | or other liability obligations and/or rights consistent with this
169 | License. However, in accepting such obligations, You may act only
170 | on Your own behalf and on Your sole responsibility, not on behalf
171 | of any other Contributor, and only if You agree to indemnify,
172 | defend, and hold each Contributor harmless for any liability
173 | incurred by, or claims asserted against, such Contributor by reason
174 | of your accepting any such warranty or additional liability.
175 |
176 | END OF TERMS AND CONDITIONS
177 |
178 | APPENDIX: How to apply the Apache License to your work.
179 |
180 | To apply the Apache License to your work, attach the following
181 | boilerplate notice, with the fields enclosed by brackets "[]"
182 | replaced with your own identifying information. (Don't include
183 | the brackets!) The text should be enclosed in the appropriate
184 | comment syntax for the file format. We also recommend that a
185 | file or class name and description of purpose be included on the
186 | same "printed page" as the copyright notice for easier
187 | identification within third-party archives.
188 |
189 | Copyright [yyyy] [name of copyright owner]
190 |
191 | Licensed under the Apache License, Version 2.0 (the "License");
192 | you may not use this file except in compliance with the License.
193 | You may obtain a copy of the License at
194 |
195 | http://www.apache.org/licenses/LICENSE-2.0
196 |
197 | Unless required by applicable law or agreed to in writing, software
198 | distributed under the License is distributed on an "AS IS" BASIS,
199 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200 | See the License for the specific language governing permissions and
201 | limitations under the License.
202 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | A library for Dart developers.
2 |
3 | Created from templates made available by Stagehand under a BSD-style
4 | [license](https://github.com/dart-lang/stagehand/blob/master/LICENSE).
5 |
6 | ## Usage
7 |
8 | A simple usage example:
9 |
10 | ```dart
11 | import 'package:dahlia_backend/dahlia_backend.dart';
12 |
13 | main() {
14 | var awesome = new Awesome();
15 | }
16 | ```
17 |
18 | ## Features and bugs
19 |
20 | Please file feature requests and bugs at the [issue tracker][tracker].
21 |
22 | [tracker]: http://example.com/issues/replaceme
23 |
--------------------------------------------------------------------------------
/analysis_options.yaml:
--------------------------------------------------------------------------------
1 | # Defines a default set of lint rules enforced for
2 | # projects at Google. For details and rationale,
3 | # see https://github.com/dart-lang/pedantic#enabled-lints.
4 | include: package:pedantic/analysis_options.yaml
5 |
6 | # For lint rules and documentation, see http://dart-lang.github.io/linter/lints.
7 | # Uncomment to specify additional rules.
8 | # linter:
9 | # rules:
10 | # - prefer_single_quotes
11 |
12 | analyzer:
13 | errors:
14 | prefer_single_quotes: ignore
15 | unnecessary_this: ignore
16 | unused_local_variable: ignore
17 | omit_local_variable_types: ignore
18 | # exclude:
19 | # - path/to/excluded/files/**
20 |
--------------------------------------------------------------------------------
/lib/dahlia_backend.dart:
--------------------------------------------------------------------------------
1 | /*
2 | Copyright 2021 The dahliaOS Authors
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | */
16 | library dahlia_backend;
17 |
18 | export 'src/api/data_provider.dart';
19 | export 'src/data/data_management.dart';
20 | export 'src/api/time_date_manager.dart';
21 | export 'src/widgets/box_container.dart';
22 | export 'src/vars/application.dart';
23 | export 'src/api/system_calls.dart';
24 | export 'src/data/feature_flags.dart';
25 | export 'src/api/device_info.dart';
26 | export 'src/api/wm/wm.dart';
27 |
28 | // TODO: Export any libraries intended for clients of this package.
29 |
--------------------------------------------------------------------------------
/lib/src/api/data_provider.dart:
--------------------------------------------------------------------------------
1 | /*
2 | Copyright 2021 The dahliaOS Authors
3 |
4 | Licensed under the Apache License, Version 2.0 (the "License");
5 | you may not use this file except in compliance with the License.
6 | You may obtain a copy of the License at
7 |
8 | http://www.apache.org/licenses/LICENSE-2.0
9 |
10 | Unless required by applicable law or agreed to in writing, software
11 | distributed under the License is distributed on an "AS IS" BASIS,
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | See the License for the specific language governing permissions and
14 | limitations under the License.
15 | */
16 | import 'dart:io';
17 |
18 | /*Stream
> dirContents(Directory dir) {
50 | var files =
>();
52 | var lister = dir.list(recursive: false);
53 | lister.listen((file) => files.add(file),
54 | onDone: () => completer.complete(files));
55 | return completer.future;
56 | }
57 |
58 | Stream