| 일 | 월 | 화 | 수 | 목 | 금 | 토 |
|---|---|---|---|---|---|---|
| 1 | ||||||
| 2 | 3 | 4 | 5 | 6 | 7 | 8 |
| 9 | 10 | 11 | 12 | 13 | 14 | 15 |
| 16 | 17 | 18 | 19 | 20 | 21 | 22 |
| 23 | 24 | 25 | 26 | 27 | 28 | 29 |
| 30 |
- 객체
- Rxjava Observable
- rxjava cold observable
- 안드로이드 유닛 테스트 예시
- 안드로이드 유닛테스트란
- jvm 작동 원리
- 서비스 쓰레드 차이
- 안드로이드 라이선스 종류
- jvm이란
- ar vr 차이
- 플러터 설치 2022
- 큐 자바 코드
- android ar 개발
- 스택 자바 코드
- 자바 다형성
- 안드로이드 os 구조
- 2022 플러터 설치
- 안드로이드 레트로핏 crud
- 멤버변수
- 클래스
- 2022 플러터 안드로이드 스튜디오
- 서비스 vs 쓰레드
- rxjava hot observable
- 안드로이드 레트로핏 사용법
- 안드로이드 유닛 테스트
- rxjava disposable
- 스택 큐 차이
- android retrofit login
- ANR이란
- 안드로이드 라이선스
- Today
- Total
목록Flutter (32)
나만을 위한 블로그
플러터 앱 구현 중 핸드폰을 흔들었음을 감지해야 하는 경우 shake 라이브러리로 구현할 수 있다.아래는 pub.dev 링크와 예시다. https://pub.dev/packages/shake shake | Flutter packageA flutter package to detect phone shakes. Adjustable G-force and reset periods.pub.devflutter pub add shake 추가만 하면 별도의 설정 없이 바로 흔들기를 감지할 수 있다.아래는 pub.dev에 있는 예시다. import 'package:flutter/material.dart';import 'package:shake/shake.dart';void main() { runApp(const MyAp..
플러터를 최신 버전으로 업그레이드하려고 설치했던 플러터를 제거한 다음 새로 설치한 후 안드로이드 스튜디오에서 플러터 프로젝트를 만들었는데 .idea 폴더만 딸랑 생성됐다.또한 cmd에서 flutter doctor를 실행하니 에러가 발생하면서 cmd가 빠르게 꺼졌다.에러가 발생한 것 같은데 에러 내용도 확인하지 못하고 cmd가 꺼져서 전체 에러는 확인하지 못했지만 아래와 같이 표시됐다. vs code에선 아래 메시지가 표시됐다. 아마 같은 에러일 거라 생각하고 어떻게 해결할까 하는데 중간에 깃 명령어가 보였다. git config --global --add safe.directory C:/flutter 에러 문구도 의심되는 소유권이 감지됐다는 내용이고 소유주가 서로 다르게 표시되어 깃 명령어를 실행하면..
플러터 인강을 듣는데 ListView.builder()를 아래처럼 구현하는 게 보였다. @overrideWidget build(BuildContext context) { return ListView.builder( shrinkWrap: true, physics: NeverScrollableScrollPhysics(), ... ), );} 플러터는 처음이라 그냥 저런 방식으로도 구현하는 거겠거니 하고 넘겼다. 완강 후 같은 강의를 듣는 동생한테 이 옵션 쓰는 거 안 좋은 거 같다는 말을 들어서 찾아본 내용을 정리한다.먼저 플러터 문서는 shrinkWrap 프로퍼티를 아래와 같이 설명한다. https://api.flutter.dev/flutter/widgets/Scroll..
https://dart.dev/language/typedefs TypedefsLearn about type aliases in Dart.dart.dev타입 별칭(type alias)은 typedef 키워드로 선언되고 타입을 간결하게 참조하는 방법이다. IntList라는 타입 별칭을 선언하고 쓰는 예는 아래와 같다 typedef IntList = List;IntList il = [1, 2, 3]; 타입 별칭은 타입 파라미터를 가질 수 있다 typedef ListMapper = Map>;Map> m1 = {}; // 장황함ListMapper m2 = {}; // 같은 내용을 더 짧고 명확하게 2.13 이전엔 typedef가 함수 타입으로만 제한됐다. 새 타입 정의를 사용하려면 최소 2.13 이상의 버전을 써..
GlobalKey는 클래스로 공식문서의 설명은 아래와 같다. https://api.flutter.dev/flutter/widgets/GlobalKey-class.html GlobalKey class - widgets library - Dart APIA key that is unique across the entire app. Global keys uniquely identify elements. Global keys provide access to other objects that are associated with those elements, such as BuildContext. For StatefulWidgets, global keys also provide access to State. Wiapi..
플러터에서 바텀 시트를 표시하는 함수는 2가지 있다. showBottomSheetshowModalBottomSheet 2가지를 모두 확인해 본다. 아래는 showBottomSheet()의 공식문서다. https://api.flutter.dev/flutter/material/ScaffoldState/showBottomSheet.html showBottomSheet method - ScaffoldState class - material library - Dart APIPersistentBottomSheetController showBottomSheet( WidgetBuilder builder, { Color? backgroundColor, double? elevation, ShapeBorder? shape,..
Hero 애니메이션은 안드로이드에서 공유 요소 전환과 같은 효과를 내는 애니메이션이다. Hero 애니메이션의 공식문서부터 먼저 확인한다. https://docs.flutter.dev/ui/animations/hero-animations Hero animationsHow to animate a widget to fly between two screens.docs.flutter.dev한 화면에서 다른 화면으로 이미지를 이동하는 걸 Hero 애니메이션이라 하며 공유 요소 전환이라고도 한다. Hero 위젯을 써서 쉽게 구현할 수 있고 MaterialPageRoute를 써서 새 경로를 지정하면 머티리얼 디자인 모션 사양에 설명된 대로 이미지가 곡선 경로를 따라 날아간다 아래는 플러터 문서에서 링크된 깃허브로 이..
격자 형태의 뷰를 플러터에서 구현하려면 GridView 클래스를 사용해서 구현할 수 있다. https://api.flutter.dev/flutter/widgets/GridView-class.html GridView class - widgets library - Dart APIA scrollable, 2D array of widgets. The main axis direction of a grid is the direction in which it scrolls (the scrollDirection). The most commonly used grid layouts are GridView.count, which creates a layout with a fixed number of tiles in the ..
제목의 2가지 키워드는 함수 포스팅에서 잠깐 나왔었다. https://onlyfor-me-blog.tistory.com/737 [Dart] 함수(Function) 알아보기Dart에도 당연히 함수는 존재한다. 그러나 사용법이 자바 / 코틀린과 매우 달라서 주의깊게 확인할 필요가 있다. 공식문서부터 쭉 읽어본다. https://dart.dev/language/functions Functions Everything about functiononlyfor-me-blog.tistory.com 이번엔 이 2가지 키워드에 대해 알아본다. 관련 공식문서는 아래를 확인한다. https://dart.dev/language/functions#parameters FunctionsEverything about functions..
리스트뷰로 여러 아이템을 표시하는 뷰를 만든 뒤 한쪽으로 스와이프해서 지우는 기능을 만들어야 할 수 있다. 이 때 사용할 수 있는 방법이 리스트뷰 안에서 Dismissible이란 위젯을 사용하는 것이다. https://api.flutter.dev/flutter/widgets/Dismissible-class.html Dismissible class - widgets library - Dart APIA widget that can be dismissed by dragging in the indicated direction. Dragging or flinging this widget in the DismissDirection causes the child to slide out of view. Followin..
