Commit 59c741c4 authored by Wilko Manger's avatar Wilko Manger

Move models to upper level in lib/

parent f13544c3
......@@ -22,7 +22,7 @@ import 'package:matrix_sdk/matrix_sdk.dart';
import 'package:shared_preferences/shared_preferences.dart';
import '../section/main/models/chat.dart';
import '../models/chat.dart';
import 'event.dart';
import 'state.dart';
......
......@@ -17,7 +17,7 @@
import 'package:equatable/equatable.dart';
import '../section/main/models/chat.dart';
import '../models/chat.dart';
abstract class ChatOrderEvent extends Equatable {
@override
......
......@@ -27,7 +27,7 @@ import 'package:moor_ffi/moor_ffi.dart';
import 'package:path/path.dart' as path;
import 'auth/bloc.dart';
import 'section/main/models/chat.dart';
import 'models/chat.dart';
class Matrix {
static final MoorStore store = MoorStore(
......
......@@ -21,7 +21,7 @@ import 'package:meta/meta.dart';
import 'chat_member.dart';
import 'chat_message.dart';
import '../../../util/room.dart';
import '../util/room.dart';
/// Chat overview used in the 'chats' page.
@immutable
......
......@@ -29,8 +29,8 @@ import 'package:meta/meta.dart';
import 'package:bloc/bloc.dart';
import 'package:matrix_sdk/matrix_sdk.dart';
import '../section/main/models/chat.dart';
import '../section/main/models/chat_member.dart';
import '../models/chat.dart';
import '../models/chat_member.dart';
import '../auth/bloc.dart';
import '../matrix.dart';
......
......@@ -18,7 +18,7 @@
import 'package:flutter/material.dart';
import 'package:intl/intl.dart';
import '../../section/main/models/chat_member.dart';
import '../../models/chat_member.dart';
import 'messages_all.dart';
......
......@@ -18,7 +18,7 @@
import 'package:flutter/material.dart';
import 'package:provider/provider.dart';
import '../section/main/models/chat_member.dart';
import '../models/chat_member.dart';
// TODO: Support branding better
......
......@@ -22,8 +22,8 @@ import 'package:matrix_sdk/matrix_sdk.dart';
import 'package:pedantic/pedantic.dart';
import 'package:meta/meta.dart';
import '../models/chat.dart';
import '../models/chat_message.dart';
import '../../../models/chat.dart';
import '../../../models/chat_message.dart';
import '../../../matrix.dart';
import '../../../util/room.dart';
......
......@@ -19,7 +19,7 @@ import 'package:matrix_sdk/matrix_sdk.dart';
import 'package:meta/meta.dart';
import 'package:equatable/equatable.dart';
import '../models/chat.dart';
import '../../../models/chat.dart';
abstract class ChatEvent extends Equatable {
@override
......
......@@ -19,7 +19,7 @@ import 'dart:async';
import 'package:bloc/bloc.dart';
import 'package:matrix_sdk/matrix_sdk.dart';
import '../../models/chat_message.dart';
import '../../../../models/chat_message.dart';
import '../../../../matrix.dart';
import 'event.dart';
......
......@@ -23,7 +23,7 @@ import 'package:matrix_sdk/matrix_sdk.dart';
import 'package:photo_view/photo_view.dart';
import 'package:photo_view/photo_view_gallery.dart';
import '../../models/chat_message.dart';
import '../../../../models/chat_message.dart';
import '../../../../matrix.dart';
......
import 'package:equatable/equatable.dart';
import '../../models/chat_message.dart';
import '../../../../models/chat_message.dart';
class ImageState extends Equatable {
final List<ChatMessage> messages;
......
......@@ -24,7 +24,7 @@ import '../../../app.dart';
import '../../../notifications/bloc.dart';
import '../../../resources/theme.dart';
import '../models/chat.dart';
import '../../../models/chat.dart';
import '../chats/widgets/typing_content.dart';
import '../widgets/chat_name.dart';
import '../widgets/title_with_sub.dart';
......
......@@ -20,7 +20,7 @@ import 'dart:async';
import 'package:bloc/bloc.dart';
import 'package:matrix_sdk/matrix_sdk.dart';
import '../../models/chat_member.dart';
import '../../../../models/chat_member.dart';
import '../../../../matrix.dart';
......
......@@ -27,8 +27,8 @@ import '../../../../resources/theme.dart';
import '../../widgets/chat_name.dart';
import '../../widgets/chat_member_tile.dart';
import '../../models/chat.dart';
import '../../models/chat_member.dart';
import '../../../../models/chat.dart';
import '../../../../models/chat_member.dart';
import '../../../../matrix.dart';
import '../../../../util/url.dart';
......
import 'package:equatable/equatable.dart';
import '../../models/chat_member.dart';
import '../../../../models/chat_member.dart';
abstract class ChatSettingsState extends Equatable {
@override
......
......@@ -18,8 +18,8 @@
import 'package:equatable/equatable.dart';
import 'package:meta/meta.dart';
import '../models/chat.dart';
import '../models/chat_message.dart';
import '../../../models/chat.dart';
import '../../../models/chat_message.dart';
class ChatState extends Equatable {
final Chat chat;
......
......@@ -17,7 +17,7 @@
import 'package:flutter/material.dart';
import '../../../../../models/chat_message.dart';
import '../../../../../../../models/chat_message.dart';
import '../../../../../widgets/redacted.dart';
import '../../../../../../../resources/theme.dart';
......
......@@ -23,8 +23,8 @@ import 'package:matrix_sdk/matrix_sdk.dart';
import 'package:provider/provider.dart';
import '../../../../models/chat.dart';
import '../../../../models/chat_message.dart';
import '../../../../../../models/chat.dart';
import '../../../../../../models/chat_message.dart';
import '../../../../../../resources/theme.dart';
......
......@@ -19,7 +19,7 @@
import 'package:flutter/material.dart';
import '../../../../../../../resources/intl/localizations.dart';
import '../../../../../models/chat_message.dart';
import '../../../../../../../models/chat_message.dart';
import '../state.dart';
......
......@@ -20,7 +20,7 @@ import 'package:flutter/material.dart';
import 'package:matrix_sdk/matrix_sdk.dart';
import '../../../../../../../resources/intl/localizations.dart';
import '../../../../../models/chat_message.dart';
import '../../../../../../../models/chat_message.dart';
import '../state.dart';
......
......@@ -20,7 +20,7 @@ import 'package:flutter/material.dart';
import '../../../../../../../resources/intl/localizations.dart';
import '../../../../../models/chat_message.dart';
import '../../../../../../../models/chat_message.dart';
import '../state.dart';
......
......@@ -19,7 +19,7 @@
import 'package:flutter/material.dart';
import '../../../../../../../resources/intl/localizations.dart';
import '../../../../../models/chat_message.dart';
import '../../../../../../../models/chat_message.dart';
import '../state.dart';
......
......@@ -21,7 +21,7 @@ import 'package:matrix_sdk/matrix_sdk.dart';
import 'package:provider/provider.dart';
import '../../../../../../resources/theme.dart';
import '../../../../models/chat_message.dart';
import '../../../../../../models/chat_message.dart';
import 'content/creation.dart';
import 'content/member_change.dart';
......
......@@ -21,7 +21,7 @@ import 'package:bloc/bloc.dart';
import '../../../chat_order/bloc.dart';
import '../models/chat.dart';
import '../../../models/chat.dart';
import '../../../matrix.dart';
......
......@@ -17,7 +17,7 @@
import 'package:bloc/bloc.dart';
import 'package:matrix_sdk/matrix_sdk.dart';
import '../../../models/chat_member.dart';
import '../../../../../models/chat_member.dart';
import '../../../../../matrix.dart';
import 'event.dart';
......
import 'package:equatable/equatable.dart';
import '../../../models/chat_member.dart';
import '../../../../../models/chat_member.dart';
abstract class CreateGroupEvent extends Equatable {
@override
......
......@@ -2,7 +2,7 @@ import 'package:meta/meta.dart';
import 'package:equatable/equatable.dart';
import 'package:matrix_sdk/matrix_sdk.dart';
import '../../../models/chat_member.dart';
import '../../../../../models/chat_member.dart';
abstract class CreateGroupState extends Equatable {
final List<ChatMember> members;
......
import 'package:meta/meta.dart';
import 'package:equatable/equatable.dart';
import '../models/chat.dart';
import '../../../models/chat.dart';
abstract class ChatsState extends Equatable {
@override
......
......@@ -20,7 +20,7 @@ import 'package:flutter/material.dart';
import 'package:transparent_image/transparent_image.dart';
import '../../../../resources/theme.dart';
import '../../models/chat.dart';
import '../../../../models/chat.dart';
import '../../../../util/chat_member.dart';
import '../../../../util/url.dart';
......
......@@ -19,7 +19,7 @@ import 'package:flutter/material.dart';
import 'package:flutter_bloc/flutter_bloc.dart';
import '../../../../app.dart';
import '../../models/chat.dart';
import '../../../../models/chat.dart';
import '../../widgets/chat_name.dart';
import '../../../../util/date_format.dart';
......
......@@ -20,7 +20,7 @@ import 'package:matrix_sdk/matrix_sdk.dart';
import 'package:provider/provider.dart';
import '../../../../../resources/theme.dart';
import '../../../models/chat.dart';
import '../../../../../models/chat.dart';
import '../../../../../matrix.dart';
......
......@@ -20,7 +20,7 @@ import 'package:matrix_sdk/matrix_sdk.dart';
import '../../../../resources/intl/localizations.dart';
import '../../../../resources/theme.dart';
import '../../models/chat.dart';
import '../../../../models/chat.dart';
class TypingContent extends StatelessWidget {
final Chat chat;
......
......@@ -18,7 +18,7 @@
import 'package:equatable/equatable.dart';
import 'package:meta/meta.dart';
import '../../models/chat_member.dart';
import '../../../../models/chat_member.dart';
@immutable
class ProfileState extends Equatable {
......
......@@ -18,7 +18,7 @@
import 'package:cached_network_image/cached_network_image.dart';
import 'package:flutter/material.dart';
import '../models/chat_member.dart';
import '../../../models/chat_member.dart';
import '../../../util/chat_member.dart';
import '../../../util/url.dart';
......
......@@ -19,7 +19,7 @@ import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import '../../../resources/theme.dart';
import '../models/chat_member.dart';
import '../../../models/chat_member.dart';
import '../../../util/chat_member.dart';
......
......@@ -19,7 +19,7 @@ import 'package:flutter/material.dart';
import 'package:meta/meta.dart';
import '../../../resources/intl/localizations.dart';
import '../models/chat.dart';
import '../../../models/chat.dart';
class ChatName extends StatelessWidget {
final Chat chat;
......
......@@ -20,7 +20,7 @@ import 'package:matrix_sdk/matrix_sdk.dart';
import '../chat/widgets/bubble/message.dart';
import '../models/chat_message.dart';
import '../../../models/chat_message.dart';
class MessageState extends StatelessWidget {
final ChatMessage message;
......
......@@ -18,7 +18,7 @@
import 'package:flutter/material.dart';
import '../../../resources/intl/localizations.dart';
import '../models/chat_message.dart';
import '../../../models/chat_message.dart';
class Redacted extends StatelessWidget {
final ChatMessage redaction;
......
......@@ -22,7 +22,7 @@ import 'package:flutter/material.dart';
import '../resources/intl/localizations.dart';
import '../resources/theme.dart';
import '../section/main/models/chat_member.dart';
import '../models/chat_member.dart';
extension ChatMemberExtension on ChatMember {
Color color(BuildContext context) =>
......
......@@ -17,7 +17,7 @@
import 'package:matrix_sdk/matrix_sdk.dart';
import '../section/main/models/chat_member.dart';
import '../models/chat_member.dart';
extension MyUserExtensions on MyUser {
ChatMember toChatMember() {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment